Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix synced folder mounting on guests having Upstart #307

Merged
merged 1 commit into from
Oct 1, 2017

Conversation

dvolosnykh
Copy link
Contributor

Update dependencies to keep on par with current Vagrant state.

machine.communicate.sudo(
"/sbin/initctl emit --no-wait vagrant-mounted MOUNTPOINT=#{expanded_guest_path}")
end
emit_upstart_notification(machine, expanded_guest_path)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

emit_upstart_notification is available only in Vagrant 2.0+, so it will break the backward compatibility.
I'd recommend trying the old notation, as it was in virtualbox provider:

        machine.communicate.sudo <<-EOH.gsub(/^ {10}/, "")
          if command -v /sbin/init && /sbin/init 2>/dev/null --version | grep upstart; then
            /sbin/initctl emit --no-wait vagrant-mounted MOUNTPOINT=#{guest_path}
          fi
        EOH

hashicorp/vagrant@9f393fc#diff-97d643b35101562477f4b556a379415fL91

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done as you suggest.

@@ -1,3 +1,4 @@
require 'rspec/collection_matchers'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just wondering - why did you add this line?

Copy link
Contributor Author

@dvolosnykh dvolosnykh Oct 1, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without this line this test file would not compile for me. There was issue with some operators that have apparently moved to collection_matches submodule.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed that line just to double check... Surprisingly, but now tests do not fail.

@legal90
Copy link
Collaborator

legal90 commented Oct 1, 2017

@dvolosnykh Thank you! I've rebased your branch to fix merge conflicts. Merging...

@legal90 legal90 merged commit 3d34985 into Parallels:master Oct 1, 2017
@dvolosnykh dvolosnykh deleted the emit_upstart branch October 2, 2017 06:48
@legal90 legal90 changed the title Fix mounting of synced folders. Fix synced folder mounting on guests having Upstart Oct 15, 2017
@legal90
Copy link
Collaborator

legal90 commented Oct 15, 2017

Released in v1.7.7

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants