Check for NFS errors only if we actually have NFS folders
This commit is contained in:
parent
a53d569656
commit
d659071a82
|
@ -30,9 +30,6 @@ module Vagrant
|
||||||
# Used by prepare_permission, so we need to save it
|
# Used by prepare_permission, so we need to save it
|
||||||
@env = env
|
@env = env
|
||||||
|
|
||||||
raise Errors::NFSNoHostIP if !env[:nfs_host_ip]
|
|
||||||
raise Errors::NFSNoGuestIP if !env[:nfs_machine_ip]
|
|
||||||
|
|
||||||
folders = {}
|
folders = {}
|
||||||
env[:machine].config.vm.synced_folders.each do |id, opts|
|
env[:machine].config.vm.synced_folders.each do |id, opts|
|
||||||
# If this synced folder doesn't enable NFS, ignore it.
|
# If this synced folder doesn't enable NFS, ignore it.
|
||||||
|
@ -60,6 +57,9 @@ module Vagrant
|
||||||
end
|
end
|
||||||
|
|
||||||
if !folders.empty?
|
if !folders.empty?
|
||||||
|
raise Errors::NFSNoHostIP if !env[:nfs_host_ip]
|
||||||
|
raise Errors::NFSNoGuestIP if !env[:nfs_machine_ip]
|
||||||
|
|
||||||
# Prepare the folder, this means setting up various options
|
# Prepare the folder, this means setting up various options
|
||||||
# and such on the folder itself.
|
# and such on the folder itself.
|
||||||
folders.each { |id, opts| prepare_folder(opts) }
|
folders.each { |id, opts| prepare_folder(opts) }
|
||||||
|
|
Loading…
Reference in New Issue