Added postgres section to Vagrantfile.template
This commit is contained in:
parent
b71d98dcea
commit
6e55c7ef47
@ -12,6 +12,7 @@ Vagrant.configure("2") do |config|
|
|||||||
|
|
||||||
num_webserver = #{numWebserver}
|
num_webserver = #{numWebserver}
|
||||||
num_loadbalancer = #{numLoadbalancers}
|
num_loadbalancer = #{numLoadbalancers}
|
||||||
|
num_postgresql = #{numPostgresql}
|
||||||
|
|
||||||
(1..num_webserver).each do |nth|
|
(1..num_webserver).each do |nth|
|
||||||
machine_id = "#{customerName}-bloated-debian-web%d" % [nth]
|
machine_id = "#{customerName}-bloated-debian-web%d" % [nth]
|
||||||
@ -36,6 +37,25 @@ Vagrant.configure("2") do |config|
|
|||||||
machine_id = "#{customerName}-bloated-debian-lb%d" % [nth]
|
machine_id = "#{customerName}-bloated-debian-lb%d" % [nth]
|
||||||
machine_ip = increment_ip()
|
machine_ip = increment_ip()
|
||||||
|
|
||||||
|
config.vm.define machine_id do |web|
|
||||||
|
web.vm.box = "ubuntu/focal64"
|
||||||
|
web.vm.hostname = machine_id
|
||||||
|
|
||||||
|
web.vm.network "private_network", ip: machine_ip
|
||||||
|
web.vm.provision "file", source: "./.ssh/id_rsa.pub", destination: "~/.ssh/authorized_keys"
|
||||||
|
|
||||||
|
web.vm.provider "virtualbox" do |vb|
|
||||||
|
vb.memory = "1024"
|
||||||
|
vb.gui = false
|
||||||
|
vb.name = machine_id
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
(1..num_postgresql).each do |nth|
|
||||||
|
machine_id = "#{customerName}-bloated-debian-db%d" % [nth]
|
||||||
|
machine_ip = increment_ip()
|
||||||
|
|
||||||
config.vm.define machine_id do |web|
|
config.vm.define machine_id do |web|
|
||||||
web.vm.box = "ubuntu/focal64"
|
web.vm.box = "ubuntu/focal64"
|
||||||
web.vm.hostname = machine_id
|
web.vm.hostname = machine_id
|
||||||
|
Loading…
x
Reference in New Issue
Block a user