fuel-library/debian/fuel-rabbit-fence.upstart
Vladimir Kuklin 6e6d1cb23c Ensure the rabbit-fence daemon started and respawned
W/o this fix, if the daemon crashed, it
would remain stopped. Also, the rabbit fence
daemon will crash on start, when there is no
/var/run/rabbitmq piddir exist.

The solution is
* add the respawn option to
the daemon's upstart (TODO for Centos inittab)
* and ensure the piddir
created by upstart/init.d before starting the daemon.

This also requires to add the rabbitmq and
fuel-rabbit-fence packages as a dependency.

Closes-bug: #1456791

Change-Id: I4e71eb9e4aa4ff3b877aa89a37d82215740aaeab
Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
2015-05-23 00:09:33 +00:00

15 lines
240 B
Plaintext

description "RabbitMQ-fence daemon"
start on runlevel [2345]
stop on runlevel [016]
respawn
respawn limit 10 5
pre-start script
mkdir -p /var/run/rabbitmq
chown -R rabbitmq /var/run/rabbitmq
end script
exec /usr/bin/rabbit-fence.py