class CF::App::Restart

Public Instance Methods

restart() click to toggle source
Uncomment to complete 50543607

input :command, :desc => “Command to restart application”, :default => nil

# File lib/cf/cli/app/restart.rb, line 15
def restart
  invoke :stop, :all => input[:all], :apps => input[:apps]

  line unless quiet?

  input[:apps].each do |app|
    unless input[:command].nil?
      app.command = input[:command]
    end
    app.update!
  end

  invoke :start, :all => input[:all], :apps => input[:apps],
    :debug_mode => input[:debug_mode]
end