Heroku json gem安装失败

时间:2018-07-06 12:48:04

标签: ruby-on-rails heroku rubygems

我无法将应用程序推送到heroku,并且在运行时出现以下错误

   An error occurred while installing json (1.8.3), and Bundler cannot continue.
   Make sure that `gem install json -v '1.8.3'` succeeds before bundling.

我也无法手动安装gem,因为

gem install json -v '1.8.3'

Fetching: json-1.8.3.gem (100%)
ERROR:  While executing gem ... (Gem::FilePermissionError)
    You don't have write permissions for the /var/lib/gems/2.3.0 directory.

我无法在Heroku上访问sudo

我该怎么办?

1 个答案:

答案 0 :(得分:0)

更新Gemlock文件,然后重试...!

或者将其完全删除,以便可以从头开始安装所有宝石