forked from l0b0/tilde
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
39 lines (36 loc) · 1.39 KB
/
Vagrantfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant::Config.run do |config|
config.vm.box = "precise32"
# Proxy
if ENV['FTP_PROXY']
config.vm.provision :shell,
:inline => "echo 'Acquire::ftp::proxy \"#{ENV['FTP_PROXY']}\";' >> /etc/apt/apt.conf.d/01proxy"
config.vm.provision :shell,
:inline => "echo 'FTP_PROXY=#{ENV['FTP_PROXY']}' >> /etc/environment"
end
if ENV['HTTP_PROXY']
config.vm.provision :shell,
:inline => "echo 'Acquire::http::proxy \"#{ENV['HTTP_PROXY']}\";' >> /etc/apt/apt.conf.d/01proxy"
config.vm.provision :shell,
:inline => "echo 'HTTP_PROXY=#{ENV['HTTP_PROXY']}' >> /etc/environment"
end
if ENV['HTTPS_PROXY']
config.vm.provision :shell,
:inline => "echo 'Acquire::https::proxy \"#{ENV['HTTPS_PROXY']}\";' >> /etc/apt/apt.conf.d/01proxy"
config.vm.provision :shell,
:inline => "echo 'HTTPS_PROXY=#{ENV['HTTPS_PROXY']}' >> /etc/environment"
end
if ENV['NO_PROXY']
config.vm.provision :shell,
:inline => "echo 'NO_PROXY=#{ENV['NO_PROXY']}' >> /etc/environment"
end
if ENV['SOCKS_PROXY']
config.vm.provision :shell,
:inline => "echo 'Acquire::socks::proxy \"#{ENV['SOCKS_PROXY']}\";' >> /etc/apt/apt.conf.d/01proxy"
config.vm.provision :shell,
:inline => "echo 'SOCKS_PROXY=#{ENV['SOCKS_PROXY']}' >> /etc/environment"
end
# Bootstrap
config.vm.provision :shell, :path => "bootstrap.sh"
end