Skip to content

Instantly share code, notes, and snippets.

@christos
Forked from shapeshed/monit.conf
Created December 17, 2011 22:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save christos/1491587 to your computer and use it in GitHub Desktop.
Save christos/1491587 to your computer and use it in GitHub Desktop.
Upstart script for monit on Ubuntu 10.04
# This is an event.d (upstart) script to keep monit running.
# To install disable the old way of doing things:
#
# /etc/init.d/monit stop && update-rc.d -f monit remove
#
# then put this script here:
#
# /etc/init/monit.conf
#
# and reload upstart configuration:
#
# initctl reload-configuration
#
# You can manually start and stop monit like this:
#
# start monit
# stop monit
#
# Michael Hale (http://halethegeek.com)
# Martin Pala (http://www.mmonit.com)
# George Ornbo (http://shapeshed.com)
description "Monit service manager"
limit core unlimited unlimited
start on runlevel [2345]
stop on runlevel [!2345]
expect daemon
respawn
exec /usr/sbin/monit -c /etc/monitrc
pre-stop exec /usr/sbin/monit -c /etc/monitrc quit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment