blue-resque 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/blue/resque.rb +1 -3
- data/lib/blue/resque/version.rb +1 -1
- data/templates/monit.conf.erb +9 -7
- metadata +4 -4
data/lib/blue/resque.rb
CHANGED
data/lib/blue/resque/version.rb
CHANGED
data/templates/monit.conf.erb
CHANGED
@@ -1,9 +1,11 @@
|
|
1
|
-
<% Blue.config.resque.
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
1
|
+
<% Blue.config.resque.each_with_index do |queues, num| %>
|
2
|
+
<% num.times do |i| %>
|
3
|
+
check process resque_worker_<%= i %>
|
4
|
+
with pidfile <%= Blue::Resque.worker_pid_path(i) %>
|
5
|
+
start program = "/bin/sh -c 'cd <%= Blue.rails_current %> ; bundle exec rake environment resque:work HOME=/home/rails/ RAILS_ENV=<%= Blue.env %> QUEUE=<%= queues %> VERBOSE=1 PIDFILE=<%= Blue::Resque.worker_pid_path(i) %> >> log/resque_worker_<%= i %>.log 2>&1 &'" as uid <%= Blue.config.user %> and gid <%= Blue.config.group %> with timeout 30 seconds
|
6
|
+
stop program = "/bin/sh -c 'cd <%= Blue.rails_current %> && kill -QUIT $(cat <%= Blue::Resque.worker_pid_path(i) %>) ; rm -f <%= Blue::Resque.worker_pid_path(i) %> ; exit 0;'"
|
7
|
+
<% if Blue.config.resque.restart_mb %>if totalmem is greater than <%= Blue.config.resque.restart_mb %> MB for 5 cycles then restart<% end %>
|
8
|
+
group resque
|
9
|
+
<% end %>
|
8
10
|
<% end %>
|
9
11
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blue-resque
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 4
|
10
|
+
version: 0.0.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Josh Sharpe
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2013-06-
|
18
|
+
date: 2013-06-09 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: bundler
|