Upgrade V1 shared folders to V2

This commit is contained in:
Mitchell Hashimoto 2013-01-23 09:27:47 -08:00
parent 4059a4ba2f
commit 29ca6bc6d1
2 changed files with 6 additions and 5 deletions

View File

@ -24,7 +24,7 @@ Vagrant.configure("2") do |config|
# Share the root folder. This can then be overridden by # Share the root folder. This can then be overridden by
# other Vagrantfiles, if they wish. # other Vagrantfiles, if they wish.
config.vm.share_folder("v-root", "/vagrant", ".") config.vm.synced_folder(".", "/vagrant", :id => "vagrant-root")
config.nfs.map_uid = :auto config.nfs.map_uid = :auto
config.nfs.map_gid = :auto config.nfs.map_gid = :auto

View File

@ -121,11 +121,12 @@ module VagrantPlugins
# Shared folders # Shared folders
self.shared_folders.each do |name, sf| self.shared_folders.each do |name, sf|
options = sf.dup options = sf.dup
guestpath = options.delete(:guestpath) options[:id] = name
hostpath = options.delete(:hostpath) guestpath = options.delete(:guestpath)
hostpath = options.delete(:hostpath)
new.vm.share_folder(name, guestpath, hostpath, options) new.vm.synced_folder(hostpath, guestpath, options)
end end
# Defined sub-VMs # Defined sub-VMs