providers/hyperv: provision action [GH-3494]

This commit is contained in:
Mitchell Hashimoto 2014-04-17 13:59:13 -07:00
parent e05bfa979e
commit 7749b8fba4
2 changed files with 25 additions and 0 deletions

View File

@ -1,5 +1,9 @@
## 1.5.4 (unreleased)
IMPROVEMENTS:
- providers/hyperv: Implement the provision command. [GH-3494]
BUG FIXES:
- core: Allow overriding of the default SSH port. [GH-3474]

View File

@ -63,6 +63,27 @@ module VagrantPlugins
end
end
def self.action_provision
Vagrant::Action::Builder.new.tap do |b|
b.use ConfigValidate
b.use Call, Created do |env, b2|
if env[:result]
b2.use Message, I18n.t("vagrant_hyperv.message_not_created")
next
end
b2.use Call, IsState, :running do |env1, b3|
if !env1[:result]
b3.use Message, I18n.t("vagrant_hyperv.message_not_running")
next
end
b3.use Provision
end
end
end
end
def self.action_resume
Vagrant::Action::Builder.new.tap do |b|
b.use HandleBox