Class: VagrantPlugins::SoftLayer::Action::ResumeInstance

Inherits:
Object
  • Object
show all
Includes:
Util::Warden
Defined in:
lib/vagrant-softlayer/action/resume_instance.rb

Overview

This resumes the suspended instance.

Instance Method Summary collapse

Methods included from Util::Warden

#sl_warden

Constructor Details

#initialize(app, env) ⇒ ResumeInstance

Returns a new instance of ResumeInstance.



8
9
10
# File 'lib/vagrant-softlayer/action/resume_instance.rb', line 8

def initialize(app, env)
  @app = app
end

Instance Method Details

#call(env) ⇒ Object



12
13
14
15
16
17
# File 'lib/vagrant-softlayer/action/resume_instance.rb', line 12

def call(env)
  env[:ui].info I18n.t("vagrant_softlayer.vm.resuming")
  sl_warden { env[:sl_machine].resume }
  
  @app.call(env)
end