[DRE-commits] [vagrant-libvirt] 07/17: Use the MixinSyncedFolders to allow us to comprehend default shared folders implementations

Antonio Terceiro terceiro at moszumanska.debian.org
Sun Apr 24 13:56:17 UTC 2016


This is an automated email from the git hooks/post-receive script.

terceiro pushed a commit to annotated tag 0.0.15
in repository vagrant-libvirt.

commit b31569b9cb4db37411b1ba910a63d7fdb82ceee1
Author: Matt Palmer <mpalmer at hezmatt.org>
Date:   Thu Jan 30 08:16:13 2014 +1100

    Use the MixinSyncedFolders to allow us to comprehend default shared folders implementations
---
 lib/vagrant-libvirt/action/prepare_nfs_settings.rb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/vagrant-libvirt/action/prepare_nfs_settings.rb b/lib/vagrant-libvirt/action/prepare_nfs_settings.rb
index 7b28d60..494457d 100644
--- a/lib/vagrant-libvirt/action/prepare_nfs_settings.rb
+++ b/lib/vagrant-libvirt/action/prepare_nfs_settings.rb
@@ -3,6 +3,8 @@ module VagrantPlugins
   module ProviderLibvirt
     module Action
       class PrepareNFSSettings
+        include Vagrant::Action::Builtin::MixinSyncedFolders
+        
         def initialize(app,env)
           @app = app
           @logger = Log4r::Logger.new("vagrant::action::vm::nfs")
@@ -27,7 +29,7 @@ module VagrantPlugins
         # we are not using NFS we don't need to do the extra work to
         # populate these fields in the environment.
         def using_nfs?
-          @machine.config.vm.synced_folders.any? { |_, opts| opts[:type] == :nfs }
+          !!synced_folders(@machine)[:nfs]
         end
 
         # Returns the IP address of the first host only network adapter

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/vagrant-libvirt.git



More information about the Pkg-ruby-extras-commits mailing list