of passage • Takes hours, often requires support • Requires documentation that’s always frequently out of date • Breaking your development environment can kill productivity for days • Produces unpredictable results Why Vagrant? Tuesday, 19 March 13
feature relies on a PHP module that is required by your web app • Module already installed on your laptop because another project that is hosted elsewhere needed it • It’s not a the server you deploy to, so the entire website stops working • You have no idea why, the same code worked on your machine • It worked on my machine! Why Vagrant? Tuesday, 19 March 13
New developers can start developing quicker • Switch between projects, versions of PHP, languages with a few commands Why Vagrant? Tuesday, 19 March 13
machine that contains all the necessary packages to use Vagrant • You can make your own from an existing VirtualBox VM or use one of the official Vagrant boxes Tuesday, 19 March 13
Bit http://files.vagrantup.com/lucid64.box Ubuntu Precise 32 Bit http://files.vagrantup.com/precise32.box Ubuntu Precise 64 Bit http://files.vagrantup.com/precise64.box Tuesday, 19 March 13
file which can be kept in version control • Easy to forward ports: Vagrant::Config.run do |config| # Forward guest port 80 to # host port 4567 config.vm.forward_port 80, 4567 end Tuesday, 19 March 13
= "web" web_config.vm.forward_port "http", 80, 8080 end config.vm.define :db do |db_config| db_config.vm.box = "db" db_config.vm.forward_port "db", 3306, 3306 end end Tuesday, 19 March 13