2014-02-15 23:29:16 +00:00
|
|
|
module VagrantPlugins
|
|
|
|
module HyperV
|
|
|
|
module Action
|
|
|
|
class StartInstance
|
|
|
|
def initialize(app, env)
|
|
|
|
@app = app
|
|
|
|
end
|
|
|
|
|
|
|
|
def call(env)
|
2014-02-26 19:12:24 +00:00
|
|
|
env[:ui].output('Starting the machine...')
|
2014-02-15 23:29:16 +00:00
|
|
|
options = { vm_id: env[:machine].id }
|
2014-02-26 19:12:42 +00:00
|
|
|
env[:machine].provider.driver.execute('start_vm.ps1', options)
|
2014-02-26 19:12:24 +00:00
|
|
|
|
2014-02-15 23:29:16 +00:00
|
|
|
@app.call(env)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|