diff --git a/lib/vagrant-hostmanager/action/update_guest.rb b/lib/vagrant-hostmanager/action/update_guest.rb index 73a7cb1..7ab7352 100644 --- a/lib/vagrant-hostmanager/action/update_guest.rb +++ b/lib/vagrant-hostmanager/action/update_guest.rb @@ -11,6 +11,14 @@ module VagrantPlugins @machine = env[:machine] @global_env = @machine.env @provider = env[:provider] + + # config_global is deprecated from v1.5 + if Gem::Version.new(::Vagrant::VERSION) >= Gem::Version.new('1.5') + @config = @global_env.vagrantfile.config + else + @config = @global_env.config_global + end + @logger = Log4r::Logger.new('vagrant::hostmanager::update_guest') end