Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: Vagrantfile

Issue 11464069: Set up statistics master server (Closed)
Patch Set: Created Aug. 23, 2013, 3:47 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 def define_standard_vm(config, host_name, ip) 1 def define_standard_vm(config, host_name, ip)
2 config.vm.define host_name do |config| 2 config.vm.define host_name do |config|
3 config.vm.box = 'precise64' 3 config.vm.box = 'precise64'
4 config.vm.box_url = 'http://files.vagrantup.com/precise64.box' 4 config.vm.box_url = 'http://files.vagrantup.com/precise64.box'
5 config.vm.host_name = "#{host_name}.adblockplus.org" 5 config.vm.host_name = "#{host_name}.adblockplus.org"
6 config.vm.network :hostonly, ip, { nic_type: '82543GC' } 6 config.vm.network :hostonly, ip, { nic_type: '82543GC' }
7 config.vm.customize ["modifyvm", :id, "--cpus", 1] 7 config.vm.customize ["modifyvm", :id, "--cpus", 1]
8 8
9 config.vm.provision :shell, :inline => ' 9 config.vm.provision :shell, :inline => '
10 if ! test -f /usr/bin/puppet; then 10 if ! test -f /usr/bin/puppet; then
11 sudo apt-get update && sudo apt-get install -y puppet 11 sudo apt-get update && sudo apt-get install -y puppet
12 fi' 12 fi'
13 13
14 manifest_files = ['vagrant.pp', 'nodes.pp'] 14 manifest_files = ['vagrant.pp', 'nodes.pp']
15 manifest_files.each do |manifest_file| 15 manifest_files.each do |manifest_file|
16 config.vm.provision :puppet do |puppet| 16 config.vm.provision :puppet do |puppet|
17 puppet.options = ['--environment=development'] 17 puppet.options = ['--environment=development']
18 puppet.manifests_path = 'manifests' 18 puppet.manifests_path = 'manifests'
19 puppet.manifest_file = manifest_file 19 puppet.manifest_file = manifest_file
20 puppet.module_path = 'modules' 20 puppet.module_path = 'modules'
21 end 21 end
22 end 22 end
23 23
24 yield(config) if block_given? 24 yield(config) if block_given?
25 end 25 end
26 end 26 end
27 27
28 Vagrant::Config.run do |config| 28 Vagrant::Config.run do |config|
29 define_standard_vm config, 'server1', '10.8.0.105' 29 define_standard_vm config, 'server1', '10.8.0.97'
Felix Dahlke 2013/08/29 14:20:45 Yuck, looks like we had the same IP for server1 an
30 define_standard_vm config, 'server3', '10.8.0.99' 30 define_standard_vm config, 'server3', '10.8.0.98'
31 define_standard_vm config, 'server4', '10.8.0.98' 31 define_standard_vm config, 'server4', '10.8.0.99'
32 define_standard_vm config, 'server5', '10.8.0.100' 32 define_standard_vm config, 'server5', '10.8.0.100'
33 define_standard_vm config, 'server6', '10.8.0.101' 33 define_standard_vm config, 'server6', '10.8.0.101'
34 define_standard_vm config, 'server7', '10.8.0.102' 34 define_standard_vm config, 'server7', '10.8.0.102'
35 define_standard_vm config, 'server8', '10.8.0.103' 35 define_standard_vm config, 'server8', '10.8.0.103'
36 define_standard_vm config, 'server9', '10.8.0.104' 36 define_standard_vm config, 'server9', '10.8.0.104'
37 define_standard_vm config, 'server10', '10.8.0.105' do |config| 37 define_standard_vm config, 'server10', '10.8.0.105' do |config|
38 config.vm.customize ["modifyvm", :id, "--memory", 1024] 38 config.vm.customize ["modifyvm", :id, "--memory", 1024]
39 end 39 end
40 define_standard_vm config, 'server11', '10.8.0.106' 40 define_standard_vm config, 'server11', '10.8.0.106'
41 define_standard_vm config, 'server12', '10.8.0.107' 41 define_standard_vm config, 'server12', '10.8.0.107'
42 define_standard_vm config, 'server13', '10.8.0.108' 42 define_standard_vm config, 'server13', '10.8.0.108'
43 define_standard_vm config, 'server14', '10.8.0.109' 43 define_standard_vm config, 'server14', '10.8.0.109'
44 define_standard_vm config, 'server15', '10.8.0.110' 44 define_standard_vm config, 'server15', '10.8.0.110'
45 define_standard_vm config, 'server17', '10.8.0.112' 45 define_standard_vm config, 'server17', '10.8.0.112'
46 define_standard_vm config, 'server18', '10.8.0.113' 46 define_standard_vm config, 'server18', '10.8.0.113'
47 define_standard_vm config, 'server19', '10.8.0.114' 47 define_standard_vm config, 'server19', '10.8.0.114'
48 define_standard_vm config, 'server20', '10.8.0.115' 48 define_standard_vm config, 'server20', '10.8.0.115'
49 define_standard_vm config, 'server21', '10.8.0.116' 49 define_standard_vm config, 'server21', '10.8.0.116'
50 define_standard_vm config, 'server22', '10.8.0.117'
50 end 51 end
OLDNEW
« no previous file with comments | « no previous file | manifests/monitoringserver.pp » ('j') | modules/statsmaster/files/stats.adblockplus.org » ('J')

Powered by Google App Engine
This is Rietveld