File tree Expand file tree Collapse file tree 2 files changed +25
-0
lines changed Expand file tree Collapse file tree 2 files changed +25
-0
lines changed Original file line number Diff line number Diff line change
1
+ /var/log/resque/*.log {
2
+ daily
3
+ missingok
4
+ rotate 7
5
+ compress
6
+ compressoptions -4
7
+ notifempty
8
+ create 640 root adm
9
+ copytruncate
10
+ }
Original file line number Diff line number Diff line change
1
+ # Borrowed with modifications from
2
+ # https://github.com/defunkt/resque/blob/master/examples/monit/resque.monit
3
+ # Replace these with your own:
4
+ # [QUEUE]
5
+ # [PATH/TO/RESQUE]
6
+ # [UID]
7
+ # [GID]
8
+ # [APP_INCLUDE]
9
+
10
+ check process resque_worker_[QUEUE]
11
+ with pidfile /var/run/resque/worker_[QUEUE].pid
12
+ start program = "/bin/sh -c 'APP_INCLUDE=[APP_INCLUDE] QUEUE=[QUEUE] VERBOSE=1 PIDFILE=/var/run/resque/worker_[QUEUE].pid nohup php -f [PATH/TO/RESQUE]/resque.php > /var/log/resque/worker_[QUEUE].log &'" as uid [UID] and gid [GID]
13
+ stop program = "/bin/sh -c 'kill -s QUIT `cat /var/run/resque/worker_[QUEUE].pid` && rm -f /var/run/resque/worker_[QUEUE].pid; exit 0;'"
14
+ if totalmem is greater than 300 MB for 10 cycles then restart # eating up memory?
15
+ group resque_workers
You can’t perform that action at this time.
0 commit comments