Commits

izazi  committed 50e889b

upgraded to the current version of vagrant[C

  • Participants
  • Parent commits 8a41bb0

Comments (0)

Files changed (1)

   { :name => :nimbus, :ip => '192.168.33.100', :cpus =>2, :memory => 512 },
   { :name => :supervisor1, :ip => '192.168.33.101', :cpus =>4, :memory => 1024 },
   { :name => :supervisor2, :ip => '192.168.33.102', :cpus =>4, :memory => 1024 },
-  { :name => :zookeeper1, :ip => '192.168.33.201', :cpus =>1, :memory => 512 }
+  { :name => :zookeeper1, :ip => '192.168.33.201', :cpus =>1, :memory => 1024 },
 ]
 
-Vagrant::Config.run do |config|
+Vagrant.configure("2") do |config|
 
   boxes.each do |opts|
   	config.vm.define opts[:name] do |config|
-  	  config.vm.box = "ubuntu12"
-	  config.vm.box_url = "http://dl.dropbox.com/u/1537815/precise64.box"
+  	  config.vm.box = "precise64"
+
+  	  config.vm.box_url = "http://files.vagrantup.com/precise64.box"
 	  
-      config.vm.network :hostonly, opts[:ip]
-      config.vm.host_name = "storm.%s" % opts[:name].to_s			
+      config.vm.network :private_network, ip: opts[:ip]
+      config.vm.hostname = "storm.%s" % opts[:name].to_s   			
       
-      config.vm.share_folder "v-data", "/vagrant_data", "./data", :transient => false
+      config.vm.synced_folder "./data", "/vagrant_data"
       
-      config.vm.customize ["modifyvm", :id, "--memory", opts[:memory]]
-      config.vm.customize ["modifyvm", :id, "--cpus", opts[:cpus] ] if opts[:cpus]
+      config.vm.provider :virtualbox do |vb|
+        vb.name = "storm.%s" % opts[:name].to_s
+        vb.customize ["modifyvm", :id, "--memory", opts[:memory]]
+        vb.customize ["modifyvm", :id, "--cpus", opts[:cpus] ] if opts[:cpus]
+      end
       
       config.vm.provision :shell, :inline => "cp -fv /vagrant_data/hosts /etc/hosts"