我已经安装了gem berkshelf(2.0.10)。
My Berksfile
site :opscode
cookbook 'memcached', '~> 1.3.0'
cookbook 'redisio', '~> 1.4.1'.
我执行命令berks。
/chef-repo$ berks
/usr/local/lib/ruby/2.1.0/fileutils.rb:250:in `mkdir': Permission denied @ dir_s_mkdir - /home/likewise-open/ZOHOCORP/siva-pt130/.rvm/gems/ruby-2.1.0/extensions/x86_64-linux/2.1.0-static/eventmachine-1.0.0.beta.3 (Errno::EACCES)
from /usr/local/lib/ruby/2.1.0/fileutils.rb:250:in `fu_mkdir'
from /usr/local/lib/ruby/2.1.0/fileutils.rb:224:in `block (2 levels) in mkdir_p'
from /usr/local/lib/ruby/2.1.0/fileutils.rb:222:in `reverse_each'
from /usr/local/lib/ruby/2.1.0/fileutils.rb:222:in `block in mkdir_p'
from /usr/local/lib/ruby/2.1.0/fileutils.rb:208:in `each'
from /usr/local/lib/ruby/2.1.0/fileutils.rb:208:in `mkdir_p'
from /usr/local/lib/ruby/2.1.0/rubygems/ext/builder.rb:210:in `write_gem_make_out'
from /usr/local/lib/ruby/2.1.0/rubygems/ext/builder.rb:132:in `build_error'
from /usr/local/lib/ruby/2.1.0/rubygems/ext/builder.rb:171:in `rescue in build_extension'
答案 0 :(得分:0)
如果您使用的是系统ruby,则需要运行:
sudo berks
答案 1 :(得分:0)
这是bundler / rubygems 2.2的问题。见bundler#2847。建议的解决方案是降级到rubygems 2.1。