Skip to content

Instantly share code, notes, and snippets.

@baxang
Forked from dipolesource/gist:1265576
Created October 24, 2011 09:27
Show Gist options
  • Save baxang/1308662 to your computer and use it in GitHub Desktop.
Save baxang/1308662 to your computer and use it in GitHub Desktop.
Log Juggernaut via Monit
check host juggernaut with address 127.0.0.1
start program = "/bin/bash -c '2>&1 1>>/home/deploy/juggernaut.log /usr/local/bin/node /usr/local/lib/node_modules/juggernaut/server.js'"
stop program = "/bin/kill -9 $(pidof node);/bin/kill -9 $(pgrep -f 'bash -c 2>&1 1>>/home/deploy/juggernaut.log')"
if failed port 8080 protocol HTTP
request /application.js
with timeout 10 seconds
then restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment