class VagrantPlugins::ProviderLibvirt::Action::PruneNFSExports
Public Class Methods
new(app, env)
click to toggle source
# File lib/vagrant-libvirt/action/prune_nfs_exports.rb, line 7 def initialize(app, env) @app = app end
Public Instance Methods
call(env)
click to toggle source
# File lib/vagrant-libvirt/action/prune_nfs_exports.rb, line 11 def call(env) if env[:host] uuid = env[:machine].id # get all uuids uuids = env[:libvirt_compute].servers.all.map(&:id) # not exiisted in array will removed from nfs uuids.delete(uuid) env[:host].capability( :nfs_prune, env[:machine].ui, uuids) end @app.call(env) end