factorylabs-fdlcap 0.2.3 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/fdlcap.gemspec +1 -1
- data/lib/fdlcap/recipes/delayed_job.rb +18 -12
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.4
|
data/fdlcap.gemspec
CHANGED
@@ -1,16 +1,22 @@
|
|
1
1
|
Capistrano::Configuration.instance(:must_exist).load do
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
define_recipe :delayed_job do
|
3
|
+
namespace :delayed_job do
|
4
|
+
desc "Start delayed_job"
|
5
|
+
task :start, :only => {:delayed_job => true} do
|
6
|
+
sudo "/usr/bin/monit start all -g dj_#{application}"
|
7
|
+
end
|
8
|
+
desc "Stop delayed_job"
|
9
|
+
task :stop, :only => {:delayed_job => true} do
|
10
|
+
sudo "/usr/bin/monit stop all -g dj_#{application}"
|
11
|
+
end
|
12
|
+
desc "Restart delayed_job"
|
13
|
+
task :restart, :only => {:delayed_job => true} do
|
14
|
+
sudo "/usr/bin/monit restart all -g dj_#{application}"
|
15
|
+
end
|
6
16
|
end
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
desc "Restart delayed_job"
|
12
|
-
task :restart, :only => {:delayed_job => true} do
|
13
|
-
sudo "/usr/bin/monit restart all -g dj_#{application}"
|
14
|
-
end
|
17
|
+
|
18
|
+
after "deploy:restart", "delayed_job:restart"
|
19
|
+
after "deploy:start", "delayed_job:start"
|
20
|
+
after "deploy:stop", "delayed_job:stop"
|
15
21
|
end
|
16
22
|
end
|