to_specs': 在 [] (Gem::LoadError) 中找不到厨师 (>= 0) [英] to_specs': Could not find chef (>= 0) amongst [] (Gem::LoadError)
问题描述
我正在尝试在我的笔记本电脑上安装 chef and knife ec2 插件来设置工作站.最初我使用 chef obibus 安装 chef-client,但安装后我遇到了一些问题,所以快速谷歌搜索让我进入 stackoverflow,几个线程建议我使用 gem 安装 chef.我在 ruby 2.0.0-p0 上运行并安装了 chef and knife ec2,但我现在遇到了不同的问题.我已经发布了这个问题,请看一下.
I am trying to install chef and knife ec2 plugin on my laptop to set up the workstation. Initially I use chef omnibus to install chef-client but after installing I encountered some problems, so a quick googling landed me to stackoverflow and couple of threads suggested me to install chef using gem. I am running on ruby 2.0.0-p0 and insalled chef and knife ec2 but I am getting a different issue now. I have posted the issue bleow, kindly have a look.
请帮我解决这个问题
/home/jeevan/.rvm/rubies/ruby-2.0.0-p0/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:247:in `to_specs': Could not find chef (>= 0) amongst [] (Gem::LoadError)
from /home/jeevan/.rvm/rubies/ruby-2.0.0-p0/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:256:in `to_spec'
from /home/jeevan/.rvm/rubies/ruby-2.0.0-p0/lib/ruby/site_ruby/2.0.0/rubygems.rb:1231:in `gem'
from /home/jeevan/.rvm/gems/ruby-2.0.0-p0/bin/chef-client:18:in `<main>'
from /home/jeevan/.rvm/gems/ruby-2.0.0-p0/bin/ruby_noexec_wrapper:14:in `eval'
from /home/jeevan/.rvm/gems/ruby-2.0.0-p0/bin/ruby_noexec_wrapper:14:in `<main>'
推荐答案
当我没有使用系统 ruby 时,这发生在我身上,感谢 RVM:
This happened to me when I wasn't using system ruby, thanks to RVM:
$ echo $GEM_HOME
/home/spiffytech/.rvm/gems/ruby-1.9.3-p448@rails3tutorial2ndEd
请注意,@rails3tutorial2ndEd
表示特殊的 Ruby 安装,而不是系统安装.
Note that @rails3tutorial2ndEd
denotes a special Ruby install, and not the system install.
为了解决这个问题并让刀再次工作,我跑了:
To fix this and make knife work again, I ran:
rvm reset
这篇关于to_specs': 在 [] (Gem::LoadError) 中找不到厨师 (>= 0)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!