forked from TIBHannover/oersi-setup
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVagrantfile
38 lines (34 loc) · 1.22 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
require 'yaml'
settings = YAML.load_file 'ansible/group_vars/all.yml'
Vagrant.configure("2") do |config|
config.vm.define "oerindex-vm" do |srv|
# Update to bullseye, because buster has bugs with vagrant & ansible currently - see https://github.com/hashicorp/vagrant/issues/13016
#srv.vm.box = "debian/buster64"
srv.vm.box = "debian/bullseye64"
srv.ssh.insert_key = false
srv.vm.hostname = "oerindex.box"
srv.vm.network :private_network, ip: settings['oerindex_host']
srv.vm.provider :virtualbox do |vb|
vb.name = "oerindex"
vb.memory = 6072
vb.cpus = 2
end
end
config.vm.provision "ansible_local" do |ansible|
ansible.install = true
ansible.compatibility_mode = "2.0"
ansible.install_mode = "pip"
ansible.pip_install_cmd = "sudo apt-get install -y python3-distutils && curl -s https://bootstrap.pypa.io/get-pip.py | sudo python3"
ansible.pip_args = "ansible-core==2.13.7"
#ansible.version = "2.13.7"
ansible.playbook = "ansible/system.yml"
ansible.galaxy_role_file = "requirements.yml"
ansible.verbose = "true"
ansible.groups = {
"oerindex" => ["oerindex-vm"],
"all:vars" => {
"timezone" => "Europe/Berlin"
}
}
end
end