forked from Juniper/vqfx10k-vagrant
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
67 lines (56 loc) · 2.21 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
# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
re_name = "vqfx"
pfe_name = "vqfx-pfe"
##############################
## Packet Forwarding Engine ##
##############################
config.vm.define pfe_name do |vqfxpfe|
vqfxpfe.ssh.insert_key = false
vqfxpfe.vm.box = 'juniper/vqfx10k-pfe'
# DO NOT REMOVE / NO VMtools installed
vqfxpfe.vm.synced_folder '.', '/vagrant', disabled: true
vqfxpfe.vm.network 'private_network', auto_config: false, nic_type: '82540EM', virtualbox__intnet: "vqfx_internal"
end
##########################
## Routing Engine #######
##########################
config.vm.define re_name do |vqfx|
vqfx.vm.hostname = "vqfx"
vqfx.vm.box = 'juniper/vqfx10k-re'
vqfx.ssh.insert_key = false
# DO NOT REMOVE / NO VMtools installed
vqfx.vm.synced_folder '.', '/vagrant', disabled: true
# Management Ports
vqfx.vm.network 'private_network', auto_config: false, nic_type: '82540EM', virtualbox__intnet: "vqfx_internal"
vqfx.vm.network 'private_network', auto_config: false, nic_type: '82540EM', virtualbox__intnet: "reserved-bridge"
## Dataplane ports
(1..5).each do |seg_id|
vqfx.vm.network 'private_network', auto_config: false, nic_type: '82540EM', virtualbox__intnet: "seg#{seg_id}"
end
end
##########################
## Server #######
##########################
config.vm.define "srv" do |srv|
srv.vm.box = "robwc/minitrusty64"
srv.vm.hostname = "server"
srv.vm.network 'private_network', ip: "10.1.2.2", virtualbox__intnet: "seg1"
srv.ssh.insert_key = true
end
##############################
## Box provisioning ###
## exclude Windows host ###
##############################
if !Vagrant::Util::Platform.windows?
config.vm.provision "ansible" do |ansible|
ansible.groups = {
"vqfx10k" => ["vqfx"],
"all:children" => ["vqfx10k"]
}
ansible.playbook = "provisioning/deploy-config.p.yaml"
end
end
end