Skip to content

Instantly share code, notes, and snippets.

@felixge
Created February 4, 2010 20:42
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 felixge/295082 to your computer and use it in GitHub Desktop.
Save felixge/295082 to your computer and use it in GitHub Desktop.
set logfile /var/log/monit.log
# nginx
check process nginx with pidfile /var/run/nginx.pid
start program = "/etc/init.d/nginx start"
stop program = "/etc/init.d/nginx stop"
if failed host 127.0.0.1 port 1111 type tcp then restart
# node.js
check host nodejs with address 127.0.0.1
start program = "/sbin/start transloadit"
stop program = "/sbin/stop transloadit"
if failed port 8003 protocol HTTP
request /
with timeout 10 seconds
then restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment