[英]can't deploy the project with capistrano
I have a ruby on rails project to be deployed with capistrano. 我有一个与capistrano一起部署的ruby on rails项目。 Basically I could deploy it with the following code. 基本上,我可以使用以下代码进行部署。
cap production deploy
But it gives me the following failure message. 但这给了我以下失败信息。
** Invoke staging (first_time)
** Execute staging
** Invoke load:defaults (first_time)
** Execute load:defaults
cap aborted!
Capfile locked at 3.2.1, but 3.3.3 is loaded
I can not find anything on this exception. 我找不到任何关于此异常的信息。 Do you know what is the real problem. 你知道什么是真正的问题。 BTW bundle update does not work. BTW捆绑包更新不起作用。
See your config/deploy.rb if there is something such as lock '3.2.1'
. 如果存在诸如lock '3.2.1'
类的内容,请参见config / deploy.rb。 Because if your Gemfile has gem capistrano, '~>3.2.1'
, it will be updated to 3.3.3 but it is locked on deploy.rb
. 因为如果您的Gemfile具有gem capistrano, '~>3.2.1'
,它将被更新为3.3.3,但是它被锁定在deploy.rb
。 Even using lock '>=3.2.1'
i am still having problem with .capistrano/metrics
in version 3.3.3. 即使使用lock '>=3.2.1'
,版本3.3.3中的.capistrano/metrics
仍然存在问题。
I added gem 'capistrano', '~> 3.2.1'
to Gemfile. 我在Gemfile中添加了gem 'capistrano', '~> 3.2.1'
。 After $ bundle update
the problem fixed. $ bundle update
,问题已解决。
Uninstall version 3.3.3 and install 3.2.1 will solve your problem. 卸载3.3.3版并安装3.2.1将解决您的问题。
1: sudo gem uninstall capistrano 1: sudo gem卸载capistrano
select the version you want to uninstall(3.3.3 in your case)
bundle exec cap production deploy
您需要在包的上下文中而不是系统中使用cap
命令。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.