]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Support to run neutron-server under systemd.
authorgustavo panizzo <gfa@zumbi.com.ar>
Mon, 28 Jul 2014 22:13:19 +0000 (19:13 -0300)
committergustavo panizzo <gfa@zumbi.com.ar>
Mon, 28 Jul 2014 23:43:35 +0000 (20:43 -0300)
Rewritten-From: 88cd13a88a0e1302c6cb748e8992e35345efe2f8

trusty/debian/changelog
trusty/debian/neutron-common.tmpfile [new file with mode: 0644]
trusty/debian/neutron-server.init
trusty/debian/neutron-server.service [new file with mode: 0644]

index 1019329eb5c7c47bcbbb17c8aa448fda4a3981e6..beb6c8149a94ea92bd15ee9db0c0f0a798efed43 100644 (file)
@@ -6,6 +6,7 @@ neutron (2014.2~b1-1) experimental; urgency=medium
 
   [ gustavo panizzo ]
   * New upstream release.
+  * Support to run neutron under systemd.
 
  -- gustavo panizzo <gfa@zumbi.com.ar>  Mon, 30 Jun 2014 18:14:04 -0300
 
diff --git a/trusty/debian/neutron-common.tmpfile b/trusty/debian/neutron-common.tmpfile
new file mode 100644 (file)
index 0000000..d9a5824
--- /dev/null
@@ -0,0 +1 @@
+d /run/neutron 0755 neutron neutron -
index 741ca489517b5ad6185d237756c294b5f36922a0..a5af3c55569e63b08c558cd56099a40493342814 100644 (file)
@@ -125,6 +125,12 @@ restart|force-reload)
 status)
        status_of_proc -p $PIDFILE $DAEMON neutron-server && exit 0 || exit $?
 ;;
+systemd-start)
+    do_start
+;;
+systemd-stop)
+    do_stop
+;;
 *)
        log_action_msg "Usage: /etc/init.d/neutron-server {start|stop|restart|force-reload|status}"
        exit 1
diff --git a/trusty/debian/neutron-server.service b/trusty/debian/neutron-server.service
new file mode 100644 (file)
index 0000000..7cfadbc
--- /dev/null
@@ -0,0 +1,17 @@
+[Unit]
+Description=OpenStack Networking service - API server
+Documentation=http://docs.openstack.org/
+After=network.service mysql.service postgresql.service rabbitmq-server.service keystone.service
+
+[Service]
+User=neutron
+Group=neutron
+ExecStart=/etc/init.d/neutron-server systemd-start
+ExecStop=/etc/init.d/neutron-server systemd-stop
+PIDFile=/var/run/neutron/neutron-server.pid
+Restart=on-failure
+Type=forking
+
+[Install]
+WantedBy=multi-user.target
+