1

我有一个 Rails gem,由于新版本存在问题,我需要降级到旧版本:aws-sdk

我已经更新了本地 Gemfile 并推送到我的 git 服务器以:

gem 'aws-sdk', '< 2.0'

现在,我需要使用降级的 gem 更新我的生产服务器,而不是它当前拥有的较新版本。

我试过cap deploy了,但收到此错误:

 ** [out :: app01-myserver.com] You are trying to install in deployment mode after changing
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] your Gemfile. Run `bundle install` elsewhere and add the
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] updated Gemfile.lock to version control.
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] You have added to the Gemfile:
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] * aws-sdk (< 2.0)
 ** [out :: app01-myserver.com] 
 ** [out :: app01-myserver.com] You have deleted from the Gemfile:
 ** [out :: app01-myserver.com] * aws-sdk

那么,我可以从命令行运行一个cap或命令来更新 Gemfile 吗?rubber

4

1 回答 1

1

如错误消息中所述,您应该将您的添加Gemfile.lock到 git。在它刚刚运行之后bundle update aws-sdk,提交更改Gemfile.lock、推送并使用cap.

于 2016-01-11T21:03:20.960 回答