-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
66 lines (62 loc) · 1.88 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
# -*- mode: ruby -*-
# vi: set ft=ruby :
ENV['VAGRANT_DEFAULT_PROVIDER'] = 'libvirt'
# Check required plugins
REQUIRED_PLUGINS_LIBVIRT = %w(vagrant-libvirt)
exit unless REQUIRED_PLUGINS_LIBVIRT.all? do |plugin|
Vagrant.has_plugin?(plugin) || (
puts "The #{plugin} plugin is required. Please install it with:"
puts "$ vagrant plugin install #{plugin}"
false
)
end
Vagrant.configure("2") do |config|
# node1 VM
config.vm.define "docker1" do |node1|
node1.vm.hostname = "docker1"
node1.vm.box = "debian/jessie64"
node1.vm.box_check_update = false
node1.vm.synced_folder '.', '/vagrant', :disabled => true
node1.vm.provider :libvirt do |domain|
domain.memory = 1024
domain.nested = true
domain.storage :file, :size => '1G'
end
end
# node2 VM
config.vm.define "docker2" do |node2|
node2.vm.hostname = "docker2"
node2.vm.box = "debian/jessie64"
node2.vm.box_check_update = false
node2.vm.synced_folder '.', '/vagrant', :disabled => true
node2.vm.provider :libvirt do |domain|
domain.memory = 1024
domain.nested = true
domain.storage :file, :size => '1G'
end
end
# node3 VM
config.vm.define "docker3" do |node3|
node3.vm.hostname = "docker3"
node3.vm.box = "debian/jessie64"
node3.vm.box_check_update = false
node3.vm.synced_folder '.', '/vagrant', :disabled => true
node3.vm.provider :libvirt do |domain|
domain.memory = 1024
domain.nested = true
domain.storage :file, :size => '1G'
end
end
# node4 VM
config.vm.define "docker4" do |node4|
node4.vm.hostname = "docker4"
node4.vm.box = "debian/jessie64"
node4.vm.box_check_update = false
node4.vm.synced_folder '.', '/vagrant', :disabled => true
node4.vm.provider :libvirt do |domain|
domain.memory = 1024
domain.nested = true
domain.storage :file, :size => '1G'
end
end
end