Created
February 14, 2010 12:51
-
-
Save badboy/303997 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cat monitrc.mustache monitrc.yml | mustace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# stripped out static data | |
# ... | |
{{#sockets}} | |
check process blog_thin{{id}} with pidfile {{blog_pid_path}}/thin.{{id}}.pid | |
start program = "{{thin}} -C {{blog_config_path}} -o {{id}} start" | |
stop program = "{{thin}} -C {{blog_config_path}} -o {{id}} stop" | |
if cpu > 60% for 2 cycles then alert | |
if cpu > 80% for 5 cycles then restart | |
if 3 restarts within 5 cycles then timeout | |
group blog_thin | |
{{/sockets}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
thin: /usr/local/bin/thin | |
blog_pid_path: /var/www/sites/blog/current/pids | |
blog_config_path: /var/www/sites/blog/current/config/thin.yml | |
sockets: | |
- { id: 0 } | |
- { id: 1 } | |
--- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment