forked from Percona-QA/package-testing
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile.template.pxc
87 lines (80 loc) · 3.8 KB
/
Vagrantfile.template.pxc
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# -*- mode: ruby -*-
# vi: set ft=ruby :
servers=[
{ :hostname => "d-jessie-64-@@hostname@@", :box => "bento/debian-8" },
{ :hostname => "d-stretch-64-@@hostname@@", :box => "bento/debian-9" },
{ :hostname => "d-buster-64-@@hostname@@", :box => "bento/debian-10" },
{ :hostname => "centos-6-64-@@hostname@@", :box => "bento/centos-6" },
{ :hostname => "centos-7-64-@@hostname@@", :box => "bento/centos-7" },
{ :hostname => "u-trusty-64-@@hostname@@", :box => "bento/ubuntu-14.04" },
{ :hostname => "u-xenial-64-@@hostname@@", :box => "bento/ubuntu-16.04" },
{ :hostname => "u-bionic-64-@@hostname@@", :box => "bento/ubuntu-18.04" },
{ :hostname => "sles-12-64-@@hostname@@", :box => "wvera/sles12sp2" }
]
Vagrant.configure("2") do |config|
# All Vagrant configuration is done here. The most pxb configuration
# options are documented and commented below. For a complete reference,
# please see the online documentation at vagrantup.com.
servers.each do |machine|
config.vm.define "pxc1-#{machine[:hostname]}" do |node1|
node1.vm.box = machine[:box]
node1.vm.hostname = machine[:hostname]
node1.vm.provider "virtualbox" do |vb|
vb.customize ["modifyvm", :id, "--cpus", 2]
vb.customize ["modifyvm", :id, "--memory", "2048", "--ioapic", "on"]
# vb.customize ["modifyvm", :id, "--nictype1", "virtio"]
# vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
# vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
config.vm.provision "ansible" do |ansible|
ansible.playbook = "@@pxc1-playbook_full@@"
ansible.become = "true"
# ansible.verbose = "vvvv"
ansible.host_key_checking = "false"
end
config.vm.synced_folder '.', '/vagrant', :disabled => true
config.vm.synced_folder '.', '/home/vagrant/sync', :disabled => true
config.vm.network :private_network, ip: "192.168.70.61"
end
config.vm.define "pxc2-#{machine[:hostname]}" do |node2|
node2.vm.box = machine[:box]
node2.vm.hostname = machine[:hostname]
node2.vm.provider "virtualbox" do |vb|
vb.customize ["modifyvm", :id, "--cpus", 2]
vb.customize ["modifyvm", :id, "--memory", "2048", "--ioapic", "on"]
# vb.customize ["modifyvm", :id, "--nictype1", "virtio"]
# vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
# vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
config.vm.provision "ansible" do |ansible|
ansible.playbook = "@@pxc2-playbook_full@@"
ansible.sudo = "true"
# ansible.verbose = "vvvv"
ansible.host_key_checking = "false"
end
config.vm.synced_folder '.', '/vagrant', :disabled => true
config.vm.synced_folder '.', '/home/vagrant/sync', :disabled => true
config.vm.network :private_network, ip: "192.168.70.62"
end
config.vm.define "pxc3-#{machine[:hostname]}" do |node3|
node3.vm.box = machine[:box]
node3.vm.hostname = machine[:hostname]
node3.vm.provider "virtualbox" do |vb|
vb.customize ["modifyvm", :id, "--cpus", 2]
vb.customize ["modifyvm", :id, "--memory", "2048", "--ioapic", "on"]
# vb.customize ["modifyvm", :id, "--nictype1", "virtio"]
# vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
# vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
config.vm.provision "ansible" do |ansible|
ansible.playbook = "@@pxc3-playbook_full@@"
ansible.sudo = "true"
# ansible.verbose = "vvvv"
ansible.host_key_checking = "false"
end
config.vm.synced_folder '.', '/vagrant', :disabled => true
config.vm.synced_folder '.', '/home/vagrant/sync', :disabled => true
config.vm.network :private_network, ip: "192.168.70.63"
end
end
end