fix cap tasks

This commit is contained in:
r888888888
2015-08-24 14:11:34 -07:00
parent 63ce7f3414
commit 59c7460456
5 changed files with 15 additions and 11 deletions

View File

@@ -1,21 +0,0 @@
namespace :web do
desc "Present a maintenance page to visitors."
task :disable do
on roles(:app) do
maintenance_html_path = "#{current_path}/public/maintenance.html.bak"
if test("[ -e #{maintenance_html_path} ]")
execute :mv, maintenance_html_path, "#{current_path}/public/maintenance.html"
end
end
end
desc "Makes the application web-accessible again."
task :enable do
on roles(:app) do
maintenance_html_path = "#{current_path}/public/maintenance.html"
if test("[ -e #{maintenance_html_path} ]")
execute :mv, maintenance_html_path, "#{current_path}/public/maintenance.html.bak"
end
end
end
end