summarylogtreecommitdiffstats
path: root/opennebula.service
diff options
context:
space:
mode:
authorRafael Reggiani Manzo2016-05-25 12:30:48 -0300
committerRafael Reggiani Manzo2016-05-25 12:30:48 -0300
commitedfa2219d881609c20a7045004df9ba8953ab59b (patch)
tree6d0c2cb2772606c12cde711cd38e6402b23161f1 /opennebula.service
parentffcbc946e7d26dace71d626f64574dba68cf93a1 (diff)
downloadaur-edfa2219d881609c20a7045004df9ba8953ab59b.tar.gz
Improve systemd service files
Now they take care of creating run and lock dirs as well as only getting up after other basic required network services. Thanks to sulaweyo at AUR comments.
Diffstat (limited to 'opennebula.service')
-rw-r--r--opennebula.service8
1 files changed, 8 insertions, 0 deletions
diff --git a/opennebula.service b/opennebula.service
index 106c3edcbd6..a6dec291299 100644
--- a/opennebula.service
+++ b/opennebula.service
@@ -1,10 +1,18 @@
[Unit]
Description=OpenNebula management
+After=network.target
+After=local-fs.target
+After=remote-fs.target
[Service]
User=oneadmin
Group=cloud
Type=forking
+PermissionsStartOnly=true
+ExecStartPre=/usr/bin/mkdir -p /var/run/one
+ExecStartPre=/usr/bin/mkdir -p /var/lock/one
+ExecStartPre=/usr/bin/chown -R oneadmin:cloud /var/run/one
+ExecStartPre=/usr/bin/chown -R oneadmin:cloud /var/lock/one
ExecStart=/usr/bin/one start
ExecStop=/usr/bin/one stop