Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 1 | # -*- mode: ruby -*- |
| 2 | # vi: set ft=ruby : |
| 3 | |
| 4 | Vagrant.configure(2) do |config| |
| 5 | |
| 6 | if (/cygwin|mswin|mingw|bccwin|wince|emx/ =~ RUBY_PLATFORM) != nil |
alshabib | b6ae086 | 2016-08-26 10:55:48 -0700 | [diff] [blame] | 7 | config.vm.synced_folder "..", "/cord", mount_options: ["dmode=700,fmode=600"] |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 8 | else |
alshabib | b6ae086 | 2016-08-26 10:55:48 -0700 | [diff] [blame] | 9 | config.vm.synced_folder "..", "/cord" |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 10 | end |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 11 | config.vm.synced_folder '.', '/vagrant', disabled: true |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 12 | |
Sapan Bhatia | 01ddea6 | 2017-02-10 11:28:48 -0800 | [diff] [blame] | 13 | config.vm.define "elastic" do |d| |
| 14 | d.ssh.forward_agent = true |
| 15 | d.vm.box = "ubuntu/trusty64" |
| 16 | d.vm.synced_folder '.', '/vagrant', disabled: true |
| 17 | |
| 18 | d.vm.network :forwarded_port, guest: 5601, host: 5601, host_ip: '*' |
| 19 | d.vm.network :forwarded_port, guest: 80, host: 9080, host_ip: '*' |
| 20 | d.vm.network :forwarded_port, guest: 9200, host: 9200, host_ip: '*' |
| 21 | d.vm.network :forwarded_port, guest: 5617, host: 5617, host_ip: '*', protocol: "udp" |
| 22 | |
| 23 | d.vm.hostname = "elastic" |
| 24 | d.vm.network "private_network", ip: "10.100.198.222" |
| 25 | d.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 26 | d.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/elastic.yml -c local" |
| 27 | d.vm.provider "virtualbox" do |v| |
| 28 | v.memory = 4096 |
| 29 | end |
| 30 | d.vm.provider :libvirt do |v, override| |
| 31 | v.memory = 4096 |
| 32 | override.vm.synced_folder "..", "/cord", type: "nfs" |
| 33 | end |
| 34 | end |
| 35 | |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 36 | config.vm.define "corddev" do |d| |
Zsolt Haraszti | 5b5a42a | 2016-05-12 22:19:57 -0700 | [diff] [blame] | 37 | d.ssh.forward_agent = true |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 38 | d.vm.box = "ubuntu/trusty64" |
| 39 | d.vm.hostname = "corddev" |
| 40 | d.vm.network "private_network", ip: "10.100.198.200" |
David K. Bainbridge | 0bdec19 | 2016-10-13 18:10:10 -0700 | [diff] [blame] | 41 | d.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 42 | d.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/corddev.yml -c local" |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 43 | d.vm.provider "virtualbox" do |v| |
| 44 | v.memory = 2048 |
| 45 | end |
Andy Bavier | 5c2e4fa | 2016-10-31 13:50:52 -0400 | [diff] [blame] | 46 | d.vm.provider :libvirt do |v, override| |
Andy Bavier | 8ce395f | 2016-10-14 12:51:30 -0400 | [diff] [blame] | 47 | v.memory = 2048 |
Andy Bavier | 5c2e4fa | 2016-10-31 13:50:52 -0400 | [diff] [blame] | 48 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 99c11d3 | 2016-09-14 17:21:20 -0400 | [diff] [blame] | 49 | end |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 50 | end |
| 51 | |
| 52 | config.vm.define "prod" do |d| |
| 53 | d.vm.box = "ubuntu/trusty64" |
| 54 | d.vm.hostname = "prod" |
Andy Bavier | 51584d4 | 2016-12-02 08:39:13 -0500 | [diff] [blame] | 55 | d.vm.network "forwarded_port", guest: 80, host: 8080, host_ip: '*' |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 56 | d.vm.network "private_network", ip: "10.100.198.201" |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 57 | d.vm.network "private_network", |
| 58 | ip: "0.0.0.0", |
| 59 | auto_config: false, |
| 60 | virtualbox__intnet: "cord-mgmt-network", |
| 61 | libvirt__network_name: "cord-mgmt-network", |
| 62 | libvirt__forward_mode: "none", |
| 63 | libvirt__dhcp_enabled: false |
| 64 | d.vm.network "private_network", |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 65 | ip: "0.1.0.0", |
| 66 | mac: "02420a060101", |
| 67 | auto_config: false, |
| 68 | virtualbox__intnet: "head-node-leaf-1", |
| 69 | libvirt__network_name: "head-node-leaf-1", |
| 70 | libvirt__forward_mode: "none", |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 71 | libvirt__dhcp_enabled: false |
David K. Bainbridge | 6f2cbe7 | 2016-08-19 15:48:07 -0700 | [diff] [blame] | 72 | d.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
alshabib | b6ae086 | 2016-08-26 10:55:48 -0700 | [diff] [blame] | 73 | d.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/prod.yml -c local" |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 74 | d.vm.provider "virtualbox" do |v| |
David K. Bainbridge | 97b3f2f | 2016-06-16 18:08:49 -0700 | [diff] [blame] | 75 | v.memory = 2048 |
| 76 | end |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 77 | d.vm.provider :libvirt do |v, override| |
Scott Baker | 6f58e32 | 2016-12-09 14:47:07 -0800 | [diff] [blame] | 78 | v.memory = 24576 |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 79 | v.cpus = 8 |
| 80 | v.storage :file, :size => '100G', :type => 'qcow2' |
Andy Bavier | 750bc6b | 2016-12-01 06:53:57 -0500 | [diff] [blame] | 81 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 82 | override.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/add-extra-drive.yml -c local" |
| 83 | end |
David K. Bainbridge | 97b3f2f | 2016-06-16 18:08:49 -0700 | [diff] [blame] | 84 | end |
| 85 | |
David K. Bainbridge | d506aa6 | 2016-06-22 16:06:39 -0700 | [diff] [blame] | 86 | config.vm.define "switch" do |s| |
| 87 | s.vm.box = "ubuntu/trusty64" |
| 88 | s.vm.hostname = "fakeswitch" |
| 89 | s.vm.network "private_network", ip: "10.100.198.253" |
| 90 | s.vm.network "private_network", |
| 91 | type: "dhcp", |
Andy Bavier | 2505f59 | 2016-11-11 15:58:55 -0500 | [diff] [blame] | 92 | virtualbox__intnet: "cord-fabric-network", |
| 93 | libvirt__network_name: "cord-fabric-network", |
David K. Bainbridge | d506aa6 | 2016-06-22 16:06:39 -0700 | [diff] [blame] | 94 | mac: "cc37ab000001" |
| 95 | s.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
alshabib | b6ae086 | 2016-08-26 10:55:48 -0700 | [diff] [blame] | 96 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/fakeswitch.yml -c local" |
David K. Bainbridge | d506aa6 | 2016-06-22 16:06:39 -0700 | [diff] [blame] | 97 | s.vm.provider "virtualbox" do |v| |
David K. Bainbridge | 97b3f2f | 2016-06-16 18:08:49 -0700 | [diff] [blame] | 98 | v.memory = 1048 |
David K. Bainbridge | d506aa6 | 2016-06-22 16:06:39 -0700 | [diff] [blame] | 99 | v.name = "fakeswitch" |
| 100 | end |
| 101 | end |
| 102 | |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 103 | config.vm.define "leaf-1" do |s| |
| 104 | s.vm.box = "ubuntu/trusty64" |
| 105 | s.vm.hostname = "leaf-1" |
| 106 | s.vm.network "private_network", |
| 107 | #type: "dhcp", |
| 108 | ip: "0.0.0.0", |
| 109 | auto_config: false, |
| 110 | virtualbox__intnet: "cord-mgmt-network", |
| 111 | libvirt__network_name: "cord-mgmt-network", |
| 112 | mac: "cc37ab000011" |
| 113 | s.vm.network "private_network", |
| 114 | ip: "0.1.0.0", |
| 115 | auto_config: false, |
| 116 | virtualbox__intnet: "head-node-leaf-1", |
| 117 | libvirt__network_name: "head-node-leaf-1", |
| 118 | libvirt__forward_mode: "none", |
| 119 | libvirt__dhcp_enabled: false |
| 120 | s.vm.network "private_network", |
| 121 | ip: "0.2.0.0", |
| 122 | auto_config: false, |
| 123 | virtualbox__intnet: "compute-node-1-leaf-1", |
| 124 | libvirt__network_name: "compute-node-1-leaf-1", |
| 125 | libvirt__forward_mode: "none", |
| 126 | libvirt__dhcp_enabled: false |
| 127 | s.vm.network "private_network", |
| 128 | ip: "0.5.0.0", |
| 129 | auto_config: false, |
| 130 | virtualbox__intnet: "leaf-1-spine-1", |
| 131 | libvirt__network_name: "leaf-1-spine-1", |
| 132 | libvirt__forward_mode: "none", |
| 133 | libvirt__dhcp_enabled: false |
| 134 | s.vm.network "private_network", |
| 135 | ip: "0.6.0.0", |
| 136 | auto_config: false, |
| 137 | virtualbox__intnet: "leaf-1-spine-2", |
| 138 | libvirt__network_name: "leaf-1-spine-2", |
| 139 | libvirt__forward_mode: "none", |
| 140 | libvirt__dhcp_enabled: false |
| 141 | s.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 142 | if (ENV['FABRIC'] == "1") |
| 143 | s.vm.provision :shell, path: "scripts/install.sh", args: "-3f" |
| 144 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/leafswitch.yml -c local -e 'fabric=true net_prefix=10.6.1'" |
| 145 | else |
| 146 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/leafswitch.yml -c local -e 'net_prefix=10.6.1'" |
| 147 | end |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 148 | s.vm.provider :libvirt do |v, override| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 149 | v.memory = 512 |
| 150 | v.cpus = 1 |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 151 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 152 | end |
| 153 | s.vm.provider "virtualbox" do |v, override| |
| 154 | v.memory = 512 |
| 155 | v.cpus = 1 |
| 156 | end |
| 157 | end |
| 158 | |
| 159 | config.vm.define "leaf-2" do |s| |
| 160 | s.vm.box = "ubuntu/trusty64" |
| 161 | s.vm.hostname = "leaf-2" |
| 162 | s.vm.network "private_network", |
| 163 | #type: "dhcp", |
| 164 | ip: "0.0.0.0", |
| 165 | auto_config: false, |
| 166 | virtualbox__intnet: "cord-mgmt-network", |
| 167 | libvirt__network_name: "cord-mgmt-network", |
| 168 | mac: "cc37ab000012" |
| 169 | s.vm.network "private_network", |
| 170 | ip: "0.3.0.0", |
| 171 | auto_config: false, |
| 172 | virtualbox__intnet: "compute-node-2-leaf-2", |
| 173 | libvirt__network_name: "compute-node-2-leaf-2", |
| 174 | libvirt__forward_mode: "none", |
| 175 | libvirt__dhcp_enabled: false |
| 176 | s.vm.network "private_network", |
| 177 | ip: "0.4.0.0", |
| 178 | auto_config: false, |
| 179 | virtualbox__intnet: "compute-node-3-leaf-2", |
| 180 | libvirt__network_name: "compute-node-3-leaf-2", |
| 181 | libvirt__forward_mode: "none", |
| 182 | libvirt__dhcp_enabled: false |
| 183 | s.vm.network "private_network", |
| 184 | ip: "0.7.0.0", |
| 185 | auto_config: false, |
| 186 | virtualbox__intnet: "leaf-2-spine-1", |
| 187 | libvirt__network_name: "leaf-2-spine-1", |
| 188 | libvirt__forward_mode: "none", |
| 189 | libvirt__dhcp_enabled: false |
| 190 | s.vm.network "private_network", |
| 191 | ip: "0.8.0.0", |
| 192 | auto_config: false, |
| 193 | virtualbox__intnet: "leaf-2-spine-2", |
| 194 | libvirt__network_name: "leaf-2-spine-2", |
| 195 | libvirt__forward_mode: "none", |
| 196 | libvirt__dhcp_enabled: false |
| 197 | s.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 198 | if (ENV['FABRIC'] == "1") |
| 199 | s.vm.provision :shell, path: "scripts/install.sh", args: "-3f" |
| 200 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/leafswitch.yml -c local -e 'fabric=true net_prefix=10.6.1'" |
| 201 | else |
| 202 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/leafswitch.yml -c local -e 'net_prefix=10.6.1'" |
| 203 | end |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 204 | s.vm.provider :libvirt do |v, override| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 205 | v.memory = 512 |
| 206 | v.cpus = 1 |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 207 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 208 | end |
| 209 | s.vm.provider "virtualbox" do |v, override| |
| 210 | v.memory = 512 |
| 211 | v.cpus = 1 |
| 212 | end |
| 213 | end |
| 214 | |
| 215 | config.vm.define "spine-1" do |s| |
| 216 | s.vm.box = "ubuntu/trusty64" |
| 217 | s.vm.hostname = "spine-1" |
| 218 | s.vm.network "private_network", |
| 219 | #type: "dhcp", |
| 220 | ip: "0.0.0.0", |
| 221 | auto_config: false, |
| 222 | virtualbox__intnet: "cord-mgmt-network", |
| 223 | libvirt__network_name: "cord-mgmt-network", |
| 224 | mac: "cc37ab000021" |
| 225 | s.vm.network "private_network", |
| 226 | ip: "0.5.0.0", |
| 227 | auto_config: false, |
| 228 | virtualbox__intnet: "leaf-1-spine-1", |
| 229 | libvirt__network_name: "leaf-1-spine-1", |
| 230 | libvirt__forward_mode: "none", |
| 231 | libvirt__dhcp_enabled: false |
| 232 | s.vm.network "private_network", |
| 233 | ip: "0.7.0.0", |
| 234 | auto_config: false, |
| 235 | virtualbox__intnet: "leaf-2-spine-1", |
| 236 | libvirt__network_name: "leaf-2-spine-1", |
| 237 | libvirt__forward_mode: "none", |
| 238 | libvirt__dhcp_enabled: false |
| 239 | s.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 240 | if (ENV['FABRIC'] == "1") |
| 241 | s.vm.provision :shell, path: "scripts/install.sh", args: "-3f" |
| 242 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/spineswitch.yml -c local -e 'fabric=true net_prefix=10.6.1'" |
| 243 | else |
| 244 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/spineswitch.yml -c local -e 'net_prefix=10.6.1'" |
| 245 | end |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 246 | s.vm.provider :libvirt do |v, override| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 247 | v.memory = 512 |
| 248 | v.cpus = 1 |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 249 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 250 | end |
| 251 | s.vm.provider "virtualbox" do |v, override| |
| 252 | v.memory = 512 |
| 253 | v.cpus = 1 |
| 254 | end |
| 255 | end |
| 256 | |
| 257 | config.vm.define "spine-2" do |s| |
| 258 | s.vm.box = "ubuntu/trusty64" |
| 259 | s.vm.hostname = "spine-2" |
| 260 | s.vm.network "private_network", |
| 261 | #type: "dhcp", |
| 262 | ip: "0.0.0.0", |
| 263 | auto_config: false, |
| 264 | virtualbox__intnet: "cord-mgmt-network", |
| 265 | libvirt__network_name: "cord-mgmt-network", |
| 266 | mac: "cc37ab000022" |
| 267 | s.vm.network "private_network", |
| 268 | ip: "0.6.0.0", |
| 269 | auto_config: false, |
| 270 | virtualbox__intnet: "leaf-1-spine-2", |
| 271 | libvirt__network_name: "leaf-1-spine-2", |
| 272 | libvirt__forward_mode: "none", |
| 273 | libvirt__dhcp_enabled: false |
| 274 | s.vm.network "private_network", |
| 275 | ip: "0.8.0.0", |
| 276 | auto_config: false, |
| 277 | virtualbox__intnet: "leaf-2-spine-2", |
| 278 | libvirt__network_name: "leaf-2-spine-2", |
| 279 | libvirt__forward_mode: "none", |
| 280 | libvirt__dhcp_enabled: false |
| 281 | s.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 282 | if (ENV['FABRIC'] == "1") |
| 283 | s.vm.provision :shell, path: "scripts/install.sh", args: "-3f" |
| 284 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/spineswitch.yml -c local -e 'fabric=true net_prefix=10.6.1'" |
| 285 | else |
| 286 | s.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/spineswitch.yml -c local -e 'net_prefix=10.6.1'" |
| 287 | end |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 288 | s.vm.provider :libvirt do |v, override| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 289 | v.memory = 512 |
| 290 | v.cpus = 1 |
Andy Bavier | ec9829a | 2017-02-05 07:58:26 -0500 | [diff] [blame] | 291 | override.vm.synced_folder "..", "/cord", type: "nfs" |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 292 | end |
| 293 | s.vm.provider "virtualbox" do |v, override| |
| 294 | v.memory = 512 |
| 295 | v.cpus = 1 |
| 296 | end |
| 297 | end |
| 298 | |
alshabib | cb8e09b | 2016-09-06 11:41:29 -0700 | [diff] [blame] | 299 | config.vm.define "testbox" do |d| |
| 300 | d.vm.box = "fgrehm/trusty64-lxc" |
| 301 | d.ssh.forward_agent = true |
| 302 | d.vm.hostname = "testbox" |
| 303 | d.vm.network "private_network", ip: "10.0.3.100", lxc__bridge_name: 'lxcbr0' |
| 304 | d.vm.provision :shell, path: "scripts/bootstrap_ansible.sh" |
| 305 | d.vm.provision :shell, inline: "PYTHONUNBUFFERED=1 ansible-playbook /cord/build/ansible/corddev.yml -c local" |
| 306 | config.vm.provider :lxc do |lxc| |
| 307 | # Same effect as 'customize ["modifyvm", :id, "--memory", "1024"]' for VirtualBox |
| 308 | lxc.customize 'cgroup.memory.limit_in_bytes', '2048M' |
alshabib | 270d766 | 2016-09-06 14:09:18 -0700 | [diff] [blame] | 309 | lxc.customize 'aa_profile', 'unconfined' |
| 310 | lxc.customize 'cgroup.devices.allow', 'b 7:* rwm' |
| 311 | lxc.customize 'cgroup.devices.allow', 'c 10:237 rwm' |
alshabib | cb8e09b | 2016-09-06 11:41:29 -0700 | [diff] [blame] | 312 | end |
David K. Bainbridge | a0a36e9 | 2016-10-13 18:05:33 -0700 | [diff] [blame] | 313 | end |
alshabib | cb8e09b | 2016-09-06 11:41:29 -0700 | [diff] [blame] | 314 | |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 315 | config.vm.define "compute-node-1" do |c| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 316 | c.vm.communicator = "none" |
| 317 | c.vm.hostname = "compute-node-1" |
| 318 | c.vm.network "private_network", |
| 319 | adapter: 1, |
| 320 | ip: "0.0.0.0", |
| 321 | auto_config: false, |
| 322 | virtualbox__intnet: "cord-mgmt-network", |
| 323 | libvirt__network_name: "cord-mgmt-network" |
| 324 | c.vm.network "private_network", |
| 325 | adapter: 2, # The fabric interface for each node |
| 326 | ip: "0.2.0.0", |
| 327 | auto_config: false, |
| 328 | virtualbox__intnet: "compute-node-1-leaf-1", |
| 329 | libvirt__network_name: "compute-node-1-leaf-1", |
| 330 | libvirt__forward_mode: "none", |
| 331 | libvirt__dhcp_enabled: false |
| 332 | c.vm.provider :libvirt do |v| |
| 333 | v.memory = 8192 |
| 334 | v.cpus = 4 |
| 335 | v.machine_virtual_size = 100 |
| 336 | v.storage :file, :size => '100G', :type => 'qcow2' |
| 337 | v.boot 'network' |
| 338 | v.boot 'hd' |
| 339 | v.nested = true |
| 340 | end |
| 341 | c.vm.provider "virtualbox" do |v, override| |
| 342 | override.vm.box = "clink15/pxe" |
| 343 | v.memory = 1048 |
| 344 | v.gui = "true" |
| 345 | end |
| 346 | end |
| 347 | |
| 348 | config.vm.define "compute-node-2" do |c| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 349 | c.vm.communicator = "none" |
| 350 | c.vm.hostname = "compute-node-2" |
| 351 | c.vm.network "private_network", |
| 352 | adapter: 1, |
| 353 | ip: "0.0.0.0", |
| 354 | auto_config: false, |
| 355 | virtualbox__intnet: "cord-mgmt-network", |
| 356 | libvirt__network_name: "cord-mgmt-network" |
| 357 | c.vm.network "private_network", |
| 358 | adapter: 2, # The fabric interface for each node |
| 359 | ip: "0.3.0.0", |
| 360 | auto_config: false, |
| 361 | virtualbox__intnet: "compute-node-2-leaf-2", |
| 362 | libvirt__network_name: "compute-node-2-leaf-2", |
| 363 | libvirt__forward_mode: "none", |
| 364 | libvirt__dhcp_enabled: false |
| 365 | c.vm.provider :libvirt do |v| |
| 366 | v.memory = 8192 |
| 367 | v.cpus = 4 |
| 368 | v.machine_virtual_size = 100 |
| 369 | v.storage :file, :size => '100G', :type => 'qcow2' |
| 370 | v.boot 'network' |
| 371 | v.boot 'hd' |
| 372 | v.nested = true |
| 373 | end |
| 374 | c.vm.provider "virtualbox" do |v, override| |
| 375 | override.vm.box = "clink15/pxe" |
| 376 | v.memory = 1048 |
| 377 | v.gui = "true" |
| 378 | end |
| 379 | end |
| 380 | |
| 381 | config.vm.define "compute-node-3" do |c| |
Andy Bavier | 0f07bb3 | 2017-01-17 10:20:26 -0500 | [diff] [blame] | 382 | c.vm.communicator = "none" |
| 383 | c.vm.hostname = "compute-node-3" |
| 384 | c.vm.network "private_network", |
| 385 | adapter: 1, |
| 386 | ip: "0.0.0.0", |
| 387 | auto_config: false, |
| 388 | virtualbox__intnet: "cord-mgmt-network", |
| 389 | libvirt__network_name: "cord-mgmt-network" |
| 390 | c.vm.network "private_network", |
| 391 | adapter: 2, # The fabric interface for each node |
| 392 | ip: "0.4.0.0", |
| 393 | auto_config: false, |
| 394 | virtualbox__intnet: "compute-node-3-leaf-2", |
| 395 | libvirt__network_name: "compute-node-3-leaf-2", |
| 396 | libvirt__forward_mode: "none", |
| 397 | libvirt__dhcp_enabled: false |
| 398 | c.vm.provider :libvirt do |v| |
| 399 | v.memory = 8192 |
| 400 | v.cpus = 4 |
| 401 | v.machine_virtual_size = 100 |
| 402 | v.storage :file, :size => '100G', :type => 'qcow2' |
| 403 | v.boot 'network' |
| 404 | v.boot 'hd' |
| 405 | v.nested = true |
| 406 | end |
| 407 | c.vm.provider "virtualbox" do |v, override| |
| 408 | override.vm.box = "clink15/pxe" |
| 409 | v.memory = 1048 |
| 410 | v.gui = "true" |
Andy Bavier | 99c11d3 | 2016-09-14 17:21:20 -0400 | [diff] [blame] | 411 | end |
| 412 | end |
| 413 | |
Zsolt Haraszti | ec7df10 | 2016-05-05 13:34:18 -0700 | [diff] [blame] | 414 | if Vagrant.has_plugin?("vagrant-cachier") |
| 415 | config.cache.scope = :box |
| 416 | end |
| 417 | |
| 418 | end |