Skip to content

Instantly share code, notes, and snippets.

@philspitler
Created August 23, 2014 18:48
Show Gist options
  • Select an option

  • Save philspitler/5a141020cac2111dab7f to your computer and use it in GitHub Desktop.

Select an option

Save philspitler/5a141020cac2111dab7f to your computer and use it in GitHub Desktop.
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "precise32"
config.vm.box_url = "http://files.vagrantup.com/precise32.box"
config.vm.network :private_network, ip: "192.168.33.85"
config.vm.network :forwarded_port, guest: 3000, host: 3000
config.vm.synced_folder "app", "/home/vagrant/app"
# Uncomment the following line to allow for symlinks
# in the app folder. This will not work on Windows, and will
# not work with Vagrant providers other than VirtualBox
# config.vm.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/app", "1"]
config.vm.provider :virtualbox do |vb|
vb.customize ["modifyvm", :id, "--name", "Bloc Vagrant", "--memory", "1024"]
end
config.vm.provision :chef_solo do |chef|
chef.add_recipe "nodejs"
chef.add_recipe "mongodb-debs"
# chef.add_recipe "redis-server"
chef.json = {
"nodejs" => {
"version" => "0.10.29"
# uncomment the following line to force
# recent versions (> 0.8.5) to be built from
# the source code
# , "from_source" => true
}
}
end
config.vm.provision :shell, :inline => "sudo apt-get install -y build-essential --no-install-recommends"
config.vm.provision :shell, :inline => "sudo apt-get install -y redis-server --no-install-recommends"
config.vm.provision :shell, :inline => "sudo apt-get install -y ruby1.9.1-dev --no-install-recommends"
config.vm.provision :shell, :inline => "sudo apt-get install -y ruby1.9.3 --no-install-recommends"
config.vm.provision :shell, :inline => "sudo gem install cf"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment