From 60a1b035e7bc1e6738081851b8f9b8b8a2e082f9 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Fri, 22 Feb 2013 15:52:57 -0800 Subject: [PATCH] For hooks, put the environment in the action env --- lib/vagrant/environment.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/vagrant/environment.rb b/lib/vagrant/environment.rb index db6424872..0399a5041 100644 --- a/lib/vagrant/environment.rb +++ b/lib/vagrant/environment.rb @@ -246,7 +246,10 @@ module Vagrant def hook(name) @logger.info("Running hook: #{name}") callable = Action::Builder.new - action_runner.run(callable, :action_name => name) + action_runner.run( + callable, + :action_name => name, + :env => self) end # This returns a machine with the proper provider for this environment.