Parallels / vagrant-parallels

Vagrant Parallels Provider

Home Page:https://parallels.github.io/vagrant-parallels

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't install vagrant-parallels despite latest Vagrant and Ruby

polarbirke opened this issue · comments

I'm failing to install vagrant-parallels via vagrant plugin install vagrant-parallels although I'm on the latest vagrant version (2.2.19). Vagrant is already using the embedded Ruby version (from /opt/vagrant/embedded/bin/ruby) 2.7.4 and not the default MacOS Big Sur version (which is 2.6.3 in my case):

% vagrant plugin install vagrant-parallels
Installing the 'vagrant-parallels' plugin. This can take a few minutes...
Vagrant failed to properly resolve required dependencies. These
errors can commonly be caused by misconfigured plugin installations
or transient network issues. The reported error is:

io-event requires Ruby version >= 3.0. The current ruby version is 2.7.4.191.

This issue also exists with the vagrant-dns plugin.

The following work-around worked for me:

git clone git@github.com:Parallels/vagrant-parallels.git
cd vagrant-parallels
bundle install
rake build
cd ../path/to/vagrant/
vagrant plugin install ../path/to/vagrant-parallels/pkg/vagrant-parallels-2.2.4.gem

It's a vagrant issue where it does not correctly resolve plugin dependencies, see hashicorp/vagrant#12640

It's a vagrant issue where it does not correctly resolve plugin dependencies, see hashicorp/vagrant#12640

Thank you for opening that issue, @fnordfish! I wanted to leave a (second) trail here for other people with plugin install problems.

I found it curious that I could install vagrant-parallels via your work-around (building it locally) even without your fixes (explicitly allowing Ruby < 3), but haven't looked deeper.

@polarbirke Looking at this projects gemspec, I believe you get this error because you are using vagrant-dns. vagrant-parallels does not seem to have any connection to io-event.
It's (another) common issue, when installing a plugin in vagrant, it might stumble about an issue in another plugin. That's because all plugins need to coexist in the same ruby environment, sharing the same dependencies.
So my guess is, when installing vagrant-parallels, vagrant tries to re-build it's dependencies and stumbles about vagrant-dns

Oh, interesting! Thanks for the explainer!

@fnordfish thank you for your support here and for resolving the vagrant-dns issue so quickly ✨

Thank you for the information, @fnordfish !

I'm gonna close this issue since it's not related to vagrant-parallels project.
To those who run into it: please refer to the upstream Vagrant issue mentioned above, hashicorp/vagrant#12640