Ne peut pas installer les plugins dans Ubuntu
J'ai essayé d'installer les plugin vbguest
, mais j'ai reçu erreurs suivantes dans le terminal:
$ vagrant plugin install vbguest
Installing the 'vbguest' plugin. This can take a few minutes...
/usr/lib/ruby/2.3.0/rubygems/specification.rb:946:in `all=': undefined method `group_by' for nil:NilClass (NoMethodError)
from /usr/lib/ruby/vendor_ruby/vagrant/bundler.rb:275:in `with_isolated_gem'
from /usr/lib/ruby/vendor_ruby/vagrant/bundler.rb:231:in `internal_install'
from /usr/lib/ruby/vendor_ruby/vagrant/bundler.rb:102:in `install'
from /usr/lib/ruby/vendor_ruby/vagrant/plugin/manager.rb:62:in `block in install_plugin'
from /usr/lib/ruby/vendor_ruby/vagrant/plugin/manager.rb:72:in `install_plugin'
from /usr/share/vagrant/plugins/commands/plugin/action/install_gem.rb:37:in `call'
from /usr/lib/ruby/vendor_ruby/vagrant/action/warden.rb:34:in `call'
from /usr/lib/ruby/vendor_ruby/vagrant/action/builder.rb:116:in `call'
from /usr/lib/ruby/vendor_ruby/vagrant/action/runner.rb:66:in `block in run'
from /usr/lib/ruby/vendor_ruby/vagrant/util/busy.rb:19:in `busy'
from /usr/lib/ruby/vendor_ruby/vagrant/action/runner.rb:66:in `run'
from /usr/share/vagrant/plugins/commands/plugin/command/base.rb:14:in `action'
from /usr/share/vagrant/plugins/commands/plugin/command/install.rb:32:in `block in execute'
from /usr/share/vagrant/plugins/commands/plugin/command/install.rb:31:in `each'
from /usr/share/vagrant/plugins/commands/plugin/command/install.rb:31:in `execute'
from /usr/share/vagrant/plugins/commands/plugin/command/root.rb:56:in `execute'
from /usr/lib/ruby/vendor_ruby/vagrant/cli.rb:42:in `execute'
from /usr/lib/ruby/vendor_ruby/vagrant/environment.rb:268:in `cli'
from /usr/bin/vagrant:173:in `<main>'
J'utilise Virtual Box 5.0.18_Ubuntu r106667 et ruby 2.3.0p0. J'ai aussi été confronté au même problème en essayant d'installer sahara
plugin. Comment puis-je résoudre ce problème?
- c'est un problème connu déjà sur certains github postes. je pense que pour l'instant la seule solution est de les installer manuellement
Vous devez vous connecter pour publier un commentaire.
Oui, il y a un problème: https://github.com/mitchellh/vagrant/issues/7073 dans
Vagrant 1.8.1
PR avec fix: https://github.com/mitchellh/vagrant/pull/7198
Le correctif doit être publié dans
Vagrant 1.8.2
.Mais jusqu'à ce que vous pouvez corriger manuellement.
Voici les étapes pour résoudre
Vagrant 1.8.1
sousUbuntu 16.04
qui aruby 2.3.0
.1.) Créer le fichier
vagrant-plugin.patch
avec le contenu suivant:2.) Appliquer le correctif:
qui fixe
/usr/lib/ruby/vendor_ruby/vagrant/bundler.rb
.patch
de commande, c'est cool! Merci pour le fixer!Lubuntu 16.04
et il a fixé le problème.Au lieu de patcher, j'ai résolu le problème en utilisant l'errance des v1.8.0 dans ubuntu 16.04:
wget https://releases.hashicorp.com/vagrant/1.8.0/vagrant_1.8.0_x86_64.deb
sudo dpkg -i vagrant_1.8.0_x86_64.deb
vagrant plugin install vagrant-vbguest
Garder un œil et de mise à niveau pour 1.8.2 quand il est sorti...
Profitez-en!
Ceci est corrigé dans la version récente de l'Errance, alors veuillez le mettre à jour.
Si vous ne pouvez exécuter cette commande pour régler le problème:
Remarque: La
sudo
autorisation est requise ou sans racine.Ce sera un patch sur votre
bundler.rb
fichier comme par PR (#7198).Vous devez également mettre à niveau votre
bundler
au moins 1.12.5 que par ce vagabond PR (#7404):J'ai la même erreur avec un autre plugin:
vagrant-triggers
J'ai trouvé un patch à appliquer sur
/usr/lib/ruby/vendor_ruby/vagrant/bundler.rb
.mais alors, vagrant entrer dans une grande boucle et essayer infiniment pour installer le package.
Parce que personne ne semble avoir mentionné jusqu'à présent, voici le voici le rapport de bug pour Ubuntu 16.04: https://bugs.launchpad.net/ubuntu/+source/vagabond/+bug/1562696
Dès à présent, personne n'a intégré le patch pour 16.04, il semble donc soit le patch manuellement ou télécharger un paquet corrigé.
mise à jour ruby a fonctionné pour moi. Ubuntu 16.04.
J'ai suivi ce guide https://www.brightbox.com/blog/2017/04/25/updated-ruby-ubuntu-packages/