【发布时间】:2014-04-24 05:48:51
【问题描述】:
我在 Rails 中使用 Unicorn 和 capistrano 部署到服务器......
但在部署的最后一步。 Capistrano 存在此错误:
INFO [47010f4f] Running /usr/bin/env service unicorn_app restart on xyzdomain.com
DEBUG [47010f4f] Command: service unicorn_app restart
DEBUG [47010f4f] Couldn't reload, starting 'cd /var/www/app/current; rvm-shell 'default' -c 'bundle exec unicorn -D -c /var/www/app/shared/config/unicorn.rb -E staging'' instead
DEBUG [47010f4f]
DEBUG [47010f4f] /etc/init.d/unicorn_app: line 42: rvm-shell: command not found
DEBUG [47010f4f]
cap aborted!
当我从服务器上的终端运行 rvm-shell 命令时,它运行时没有错误。
注意:rvm-shell 安装在 ~/.rvm/bin 中。所以这与这里提到的错误不同:https://github.com/capistrano/capistrano/issues/43
为什么会这样?
【问题讨论】:
标签: ruby-on-rails ruby-on-rails-4 capistrano unicorn rvm-capistrano