Reputation: 10642
In my Vagrantfile (Vagrant 1.7.4) I have the following:
config.vm.synced_folder ".", "/home/vagrant/sync", type: "rsync", :mount_options => ["dmode=777", "fmode=666"], rsync__exclude: [".git/"]
When I issue vagrant up
, it outputs the following:
==> default: Rsyncing folder: /project/ => /home/vagrant/sync
==> default: - Exclude: [".vagrant", ".git/",]
==> default: Mounting shared folders...
default: /vagrant => /project
I don't understand why there is a shared and a synced folder. I'm using virtualbox so i understand these are the same but I just want a shared folder - why are there 2?
Upvotes: 1
Views: 749
Reputation: 53793
So first sync folder is the Vagrant term for Virtual Box shared folder, so you're correct to say the 2 are the same. Now coming to your question,
By default, Vagrant will share your project directory (the directory with the Vagrantfile) to /vagrant.
This is defined as config.vm.synced_folder ".", "/vagrant"
; so this one always comes, if you define or not new sync folder.
If you want not to have the default sync folder, you can add the following to your Vagrant file
config.vm.synced_folder ".", "/vagrant", disabled: true
Upvotes: 2