-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVagrantfile
35 lines (28 loc) · 998 Bytes
/
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
# Alternative oss boxes: https://app.vagrantup.com/bento
# groups with ip's
# - metal => machine1 | vagrant ;
# - simple_web-container => swc-01 | 172.0.0.1 ;
# virtual groups
# - simple_web -> simple_web-container,
# - container -> simple_web-container,
Vagrant.configure("2") do |config|
config.vm.define "machine1"
#
# Run Ansible from the Vagrant Host
#
config.vm.network "forwarded_port", guest: 8321, host: 8321
config.vm.network "forwarded_port", guest: 8322, host: 8322
config.vm.box = "bento/debian-10.11"
config.vm.provision "ansible" do |ansible|
ansible.playbook = "playbook.yml"
# https://github.com/hashicorp/vagrant/issues/9893
ansible.raw_arguments = ["--inventory", "inventory" ]
# ansible.groups = {
# "metal" => ["machine1"],
#"simple_web" => ["simple_web-container"],
#"container" => ["simple_web-container"],
# }
# ansible.verbose = "vvv"
# ansible.tags = "network"
end
end