forked from queeno/ansible-uchiwa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
34 lines (32 loc) · 1.04 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
machines = {
'debian' => {
'ip' => '192.168.33.2',
'box' => 'ubuntu/trusty64',
'local_port' => '8080',
},
'redhat' => {
'ip' => '192.168.33.3',
'box' => 'bento/centos-7.1',
'local_port' => '8081',
}
}
Vagrant.configure('2') do |config|
machines.each do |vm, specs|
config.vm.define vm do |machine|
machine.vm.hostname = "#{vm}-standalone"
machine.vm.network :private_network, :ip => specs['ip']
machine.vm.network "forwarded_port", guest: 3000, host: specs['local_port']
machine.vm.box = specs['box']
machine.vm.provision 'ansible' do |ansible|
ansible.playbook = 'vagrant/site.yml'
ansible.groups = {
'debian' => ['debian-standalone'],
'redhat' => ['redhat-standalone']
}
ansible.limit = "#{vm}"
ansible.sudo = true
ansible.host_key_checking = false
end
end
end
end