Class: EY::CLI::Web
Instance Method Summary collapse
Instance Method Details
#disable ⇒ Object
47 48 49 50 51 |
# File 'lib/engineyard/cli/web.rb', line 47 def disable app_env = fetch_app_environment([:app], [:environment], [:account]) ui.info "Putting up maintenance page for '#{app_env.app.name}' in '#{app_env.environment.name}'" serverside_runner(app_env, [:verbose]).put_up_maintenance_page.call(ui.out, ui.err) end |
#enable ⇒ Object
17 18 19 20 21 |
# File 'lib/engineyard/cli/web.rb', line 17 def enable app_env = fetch_app_environment([:app], [:environment], [:account]) ui.info "Taking down maintenance page for '#{app_env.app.name}' in '#{app_env.environment.name}'" serverside_runner(app_env, [:verbose]).take_down_maintenance_page.call(ui.out, ui.err) end |
#restart ⇒ Object
73 74 75 76 77 78 79 80 81 |
# File 'lib/engineyard/cli/web.rb', line 73 def restart app_env = fetch_app_environment([:app], [:environment], [:account]) ui.info "Restarting servers on #{app_env.hierarchy_name}" if serverside_runner(app_env, [:verbose]).restart.call(ui.out, ui.err) ui.info "Restart complete" else raise EY::Error, "Restart failed" end end |