-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVagrantfile
36 lines (30 loc) · 1.11 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
# -*- mode: ruby -*-
# vi: set ft=ruby :
# ENV['VAGRANT_EXPERIMENTAL'] = "disks"
Vagrant.configure("2") do |config|
config.vm.box = "wate/debian-11"
config.vm.network "forwarded_port", guest: 80, host: 8080
config.vm.network "forwarded_port", guest: 3306, host: 3306
config.vm.network "private_network", ip: "192.168.56.200"
config.vm.synced_folder "./", "/vagrant"
config.vm.provider "virtualbox" do |vb|
vb.memory = "1024"
end
config.vm.disk :disk, name: "extra_strage", size: "20GB"
if Vagrant.has_plugin?('vagrant-vbguest')
config.vbguest.auto_update = false
end
ansible_extra_vars = {}
extra_var_file = File.expand_path(File.join(File.dirname(__FILE__), 'extra_vars.yml'))
if File.exists?(extra_var_file)
ansible_extra_vars = YAML.load_file(extra_var_file)
end
config.vm.provision "ansible_local" do |ansible|
ansible.become = true
ansible.compatibility_mode = "2.0"
ansible.provisioning_path = "/vagrant/provision"
ansible.playbook = "playbook.yml"
ansible.config_file = "/vagrant/provision/ansible.cfg"
ansible.extra_vars = ansible_extra_vars
end
end