-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
36 lines (32 loc) · 1.01 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
require 'yaml'
settings = YAML.load(IO.read('vagrant_secure_settings.yml'))
Vagrant.configure("2") do |config|
config.vm.box = "dhoppe/debian-8.0.0-amd64-nocm"
config.vm.provider :vmware_fusion do |provider, override|
provider.vmx["memsize"] = "1024"
provider.vmx["mks.enable3d"] = "FALSE"
provider.vmx["mks.vsync"] = "1"
provider.gui = false
end
config.vm.define "blog" do |host|
host.vm.network :forwarded_port, guest: 80, host: 30080
end
config.vm.provision :ansible do |ansible|
ansible.playbook = "site.yml"
ansible.sudo = true
ansible.host_key_checking = false
ansible.verbose = 'v'
if ENV['ANSIBLE_INVENTORY'].nil?
ansible.inventory_path = "development"
else
ansible.inventory_path = ENV['ANSIBLE_INVENTORY']
end
ansible.limit = 'blog'
if !ENV['ANSIBLE_TAG'].nil?
ansible.tags = ENV['ANSIBLE_TAG']
end
unless ENV['ANSIBLE_INVENTORY'].nil?
ansible.extra_vars = "secure_settings/#{ENV['ANSIBLE_INVENTORY']}.yml"
end
end
end