Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2014
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. check process sidekiq_1 with pidfile /tmp/pids/sidekiq_1.pid
  2. start program = "/bin/bash -l -c 'bundle exec sidekiq start" as uid jim and gid jim with timeout 250 seconds
  3. stop program = "/bin/bash -l -c 'bundle exec sidekiq stop" as uid jim and gid jim with timeout 120 seconds
  4. if cpu usage > 25% for 18 cycles then restart
  5. if mem > 1500.0 MB for 18 cycles then restart
  6.  
  7. monit unmonitor sidekiq_1
  8.  
  9. monit monitor sidekiq_1
  10.  
  11. ################################################################################
  12. # Shutdown Cucumber
  13. ################################################################################
  14. 01 15 * * 1-5 monit unmonitor `/bin/hostname`
  15. 50 23 * * 0-5 monit -g servers stop all
  16. 51 23 * * 0-5 monit -g base stop all
  17. 52 23 * * 0-5 monit stop all
  18.  
  19. jim ALL=NOPASSWD: /usr/bin/monit unmonitor sidekiq_1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement