lib/berkshelf/vagrant/plugin.rb in vagrant-berkshelf-1.3.3 vs lib/berkshelf/vagrant/plugin.rb in vagrant-berkshelf-1.3.4
- old
+ new
@@ -4,12 +4,13 @@
class << self
def provision(hook)
hook.after(::Vagrant::Action::Builtin::Provision, Berkshelf::Vagrant::Action.upload)
hook.after(::Vagrant::Action::Builtin::Provision, Berkshelf::Vagrant::Action.install)
- if ::VagrantPlugins.const_defined?(:AWS)
- hook.after(::VagrantPlugins::AWS::Action::TimedProvision, Berkshelf::Vagrant::Action.upload)
- hook.after(::VagrantPlugins::AWS::Action::TimedProvision, Berkshelf::Vagrant::Action.install)
+ # vagrant-aws < 0.4.0 uses a non-standard provision action
+ if defined?(VagrantPlugins::AWS::Action::TimedProvision)
+ hook.after(VagrantPlugins::AWS::Action::TimedProvision, Berkshelf::Vagrant::Action.upload)
+ hook.after(VagrantPlugins::AWS::Action::TimedProvision, Berkshelf::Vagrant::Action.install)
end
hook.before(::Vagrant::Action::Builtin::ConfigValidate, Berkshelf::Vagrant::Action.setup)
end
end