Skip to content

Instantly share code, notes, and snippets.

@joeshaw
Created Sep 20, 2011
Embed
What would you like to do?
monit configuration
set daemon 10
set logfile /var/log/monit.log
set statefile /var/lib/monit/monit.state
set alert foo@example.com not { nonexist, action, instance }
include /etc/monit/conf.d/*
check process myservice
with pidfile /var/run/myservice/myservice.pid
start program = "/home/myservice/current/start-myservice.sh"
as uid myservice and gid myservice
stop program = "/home/myservice/current/stop-myservice.sh"
as uid myservice and gid myservice
mode active
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment