![](/img/trans.png)
[英]Gem not found in any of the sources when deploying with Capistrano
[英]Puma gem not found when deploying with Capistrano
我想將Capistrano和Puma的應用程序部署到VPS,但是每次出現此錯誤時:
INFO [17b91266] Running RBENV_ROOT=~/.rbenv RBENV_VERSION=2.2.4 ~/.rbenv/bin/rbenv exec bundle exec puma -C /home/deploy/applications/app/shared/puma.rb --daemon as deploy@11.111.11.11
(Backtrace restricted to imported tasks)
cap aborted!
SSHKit::Runner::ExecuteError: Exception while executing as deploy@11.111.11.11: Exception while executing as deploy@11.111.11.11: bundle exit status: 127
bundle stdout: bundler: command not found: puma
Install missing gem executables with `bundle install`
bundle stderr: Nothing written
的Gemfile:
gem 'puma'
group :production do
gem 'capistrano-rails'
gem 'capistrano-bundler'
gem 'capistrano-rbenv'
gem 'capistrano3-puma'
end
Capfile:
require 'capistrano/setup'
require 'capistrano/deploy'
require 'capistrano/rbenv'
require 'capistrano/bundler'
require 'capistrano/rails'
require 'capistrano/puma'
解決了問題。 我沒有使用最新更改來更新分支“ master”。
看起來您需要在服務器上運行rbenv rehash
,這就是為什么它找不到puma可執行文件的原因
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.