Skip to content

Instantly share code, notes, and snippets.

@kotashiratsuka
Created October 7, 2014 07:26
Show Gist options
  • Save kotashiratsuka/13e97865f17a77d19c06 to your computer and use it in GitHub Desktop.
Save kotashiratsuka/13e97865f17a77d19c06 to your computer and use it in GitHub Desktop.
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.ssh.forward_agent = true
vms = [
{ :name => "consal1", :ip => "10.10.10.10" },
{ :name => "consal2", :ip => "10.10.10.12" },
{ :name => "consal3", :ip => "10.10.10.13" }
]
config.vm.box = "insaneworks/centos"
vms.each do |param|
config.vm.define param[:name] do |config|
config.vm.network :forwarded_port, guest: 8500, host: 8500 if param[:name] == "consal3"
config.vm.network :private_network, ip: param[:ip]
config.vm.host_name = "%s.vagrant" % param[:name]
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment