alankent/vagrant-magento2-apache-base — pull request #2 by astorm (2014-12-21 21:18:31+00:00)
Title: OS X Permissions fix

Using Vagrant 1.6.5 with Virtual Box 4.3.2 on OS X 10.10.1 (Yosemite), the default vagrant setup results in a number of permissions errors that prevent Magento from running. Magento can't write to the `var/cache` folder or the `var/generation` folder, and new folders/files created from a web context seem to ignore PHP's umask setting and are created without the necessary write permissions.

Having the `/var/www/magento2` folder sync with

config.vm.synced_folder "../magento2", "/var/www/magento2", :mount_options => ["dmode=777","fmode=666"]

appears to fix this problem, ("appears to" because I'm not familiar enough with how Vagrant handles permissions, umasks, etc. between the host/guest OS to know for certain that this has completely solved the problem)

Assuming this doesn't interfere with other systems, it'd be a good idea to ship with this as the default so Mac users don't run into this problem.