nomagic_capistrano_recipes 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -151,12 +151,21 @@ module NomagicCapistranoRecipes
|
|
|
151
151
|
set(:unicorn_pid) { "#{deploy_to}/#{shared_dir}/pids/unicorn.pid" }
|
|
152
152
|
|
|
153
153
|
task :restart do
|
|
154
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
155
|
+
puts "Restarting unicorn"
|
|
156
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
154
157
|
run "if [ -f #{unicorn_pid} ] && [ -e /proc/$(cat #{unicorn_pid}) ]; then kill -USR2 `cat #{unicorn_pid}`; else cd #{deploy_to}/current && bundle exec unicorn -c #{unicorn_conf} -E #{rails_env} -D; fi"
|
|
155
158
|
end
|
|
156
159
|
task :start do
|
|
160
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
161
|
+
puts "Starting unicorn"
|
|
162
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
157
163
|
run "cd #{deploy_to}/current && bundle exec unicorn -c #{unicorn_conf} -E #{rails_env} -D"
|
|
158
164
|
end
|
|
159
165
|
task :stop do
|
|
166
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
167
|
+
puts "Stopping unicorn"
|
|
168
|
+
puts "-----------------------------------------------------------------------------------------"
|
|
160
169
|
run "if [ -f #{unicorn_pid} ] && [ -e /proc/$(cat #{unicorn_pid}) ]; then kill -QUIT `cat #{unicorn_pid}`; fi"
|
|
161
170
|
end
|
|
162
171
|
end
|