Sha256: e8fd7f9593aa3634bfce1b8f4b0098f01dc3680255e716653952f8a036c40dd2
Contents?: true
Size: 780 Bytes
Versions: 4
Compression:
Stored size: 780 Bytes
Contents
module Vagrant module Notify module Action class SetSharedFolder def initialize(app, env) @app = app end def call(env) begin unless env[:machine].config.notify.enable == false host_dir = Pathname("/tmp/vagrant-notify/#{env[:machine].index_uuid}") FileUtils.mkdir_p host_dir.to_s unless host_dir.exist? env[:machine].config.vm.synced_folder host_dir, "/tmp/vagrant-notify", id: "vagrant-notify" end @app.call(env) rescue Vagrant::Errors::GuestCapabilityNotFound env[:machine].ui.warn("vagrant-notify: guest does not support the shared folder capability.") end end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems