-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
69 lines (59 loc) · 2.82 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
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
# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "trusty64"
config.vm.define "controller" do |machine|
machine.vm.network :private_network, ip: "10.11.0.2", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.12.0.2", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.14.0.2", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.15.0.2", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.16.80.2", :netmask => "255.255.255.0"
machine.vm.hostname = "controller"
machine.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 2048]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
end
end
config.vm.define "compute" do |machine|
machine.vm.network :private_network, ip: "10.11.0.3", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.13.0.3", :netmask => "255.255.255.0"
machine.vm.hostname = "compute"
machine.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 2048]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
end
end
config.vm.define "network" do |machine|
machine.vm.network :private_network, ip: "10.11.0.4", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.13.0.4", :netmask => "255.255.255.0"
machine.vm.network :private_network, ip: "10.14.0.4", :netmask => "255.255.255.0"
machine.vm.hostname = "network"
machine.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 1024]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
v.customize ["modifyvm", :id, "--nicpromisc4", "allow-all"]
end
end
config.vm.define "image" do |machine|
machine.vm.network :private_network, ip: "10.11.0.5", :netmask => "255.255.255.0"
machine.vm.hostname = "image"
machine.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 1024]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
end
end
cinder_file_to_disk = '.vagrant/cinder-volume-extradisk.vdi'
config.vm.define "volume" do |machine|
machine.vm.network :private_network, ip: "10.11.0.6", :netmask => "255.255.255.0"
machine.vm.hostname = "volume"
machine.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 1024]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
v.customize ["createhd", "--filename", cinder_file_to_disk, "--size", 4096]
v.customize ["storageattach", :id, "--storagectl", "SATAController",
"--port", 2, "--device", 0, "--type", "hdd",
"--medium", cinder_file_to_disk]
end
end
end