summaryrefslogtreecommitdiffstats
path: root/Rakefile
diff options
context:
space:
mode:
authorTails developers <amnesia@boum.org>2012-05-22 11:27:27 +0200
committerTails developers <amnesia@boum.org>2012-05-22 11:27:27 +0200
commitba17dcaaf9b2857d7669ae40d20237053c0319f8 (patch)
tree1cc5cd4c52d155bc6df43a01b55da915f0ed2c1e /Rakefile
parent83ac60274fd5a679c38e504e9ce9620d03997c4f (diff)
vagrant: Do not use in-VM proxy to download the basebox
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile8
1 files changed, 8 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile
index 8ca0c2b..9a4f4b6 100644
--- a/Rakefile
+++ b/Rakefile
@@ -200,6 +200,12 @@ namespace :vm do
env = Vagrant::Environment.new(:cwd => VAGRANT_PATH, :ui_class => Vagrant::UI::Basic)
case env.primary_vm.state
when :not_created
+ # Do not use non-existant in-VM proxy to download the basebox
+ if ENV['http_proxy'] == INTERNEL_HTTP_PROXY
+ ENV['http_proxy'] = nil
+ restore_internal_proxy = true
+ end
+
$stderr.puts <<-END_OF_MESSAGE.gsub(/^ /, '')
This is the first time that the Tails builder virtual machine is
@@ -247,6 +253,8 @@ namespace :vm do
end
result = env.cli('up')
abort "'vagrant up' failed" unless result
+
+ ENV['http_proxy'] = INTERNEL_HTTP_PROXY if restore_internal_proxy
end
desc 'Stop the build virtual machine'