Vagrantfile 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # -*- mode: ruby -*-
  2. # vi: set ft=ruby :
  3. Vagrant.configure("2") do |config|
  4. # All Vagrant configuration is done here. The most common configuration
  5. # options are documented and commented below. For a complete reference,
  6. # please see the online documentation at vagrantup.com.
  7. # Every Vagrant virtual environment requires a box to build off of.
  8. config.vm.box = "ubuntu/trusty64"
  9. forward_port = ->(guest, host = guest) do
  10. config.vm.network :forwarded_port,
  11. guest: guest,
  12. host: host,
  13. auto_correct: true
  14. end
  15. # Sync between the web root of the VM and the 'sites' directory
  16. config.vm.synced_folder "sites/", "/var/www"
  17. forward_port[1080] # mailcatcher
  18. forward_port[3306] # mysql
  19. forward_port[80, 80] # nginx/apache
  20. config.vm.provision :shell do |shell|
  21. shell.inline = "puppet module install --force puppetlabs-stdlib"
  22. shell.inline = "puppet module install --force puppetlabs-apache"
  23. end
  24. config.vm.provision :puppet do |puppet|
  25. puppet.manifests_path = "manifests"
  26. puppet.manifest_file = "default.pp"
  27. end
  28. config.vm.network :private_network, ip: "33.33.33.10"
  29. end