From: gustavo panizzo Date: Mon, 28 Jul 2014 22:13:19 +0000 (-0300) Subject: Support to run neutron-server under systemd. X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=741b7286b1643d44bb722170f2d1fcdb639abc41;p=openstack-build%2Fneutron-build.git Support to run neutron-server under systemd. Rewritten-From: 88cd13a88a0e1302c6cb748e8992e35345efe2f8 --- diff --git a/xenial/debian/changelog b/xenial/debian/changelog index 1019329eb..beb6c8149 100644 --- a/xenial/debian/changelog +++ b/xenial/debian/changelog @@ -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 Mon, 30 Jun 2014 18:14:04 -0300 diff --git a/xenial/debian/neutron-common.tmpfile b/xenial/debian/neutron-common.tmpfile new file mode 100644 index 000000000..d9a582460 --- /dev/null +++ b/xenial/debian/neutron-common.tmpfile @@ -0,0 +1 @@ +d /run/neutron 0755 neutron neutron - diff --git a/xenial/debian/neutron-server.init b/xenial/debian/neutron-server.init index 741ca4895..a5af3c555 100644 --- a/xenial/debian/neutron-server.init +++ b/xenial/debian/neutron-server.init @@ -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/xenial/debian/neutron-server.service b/xenial/debian/neutron-server.service new file mode 100644 index 000000000..7cfadbcda --- /dev/null +++ b/xenial/debian/neutron-server.service @@ -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 +