任何人都可以告诉我如何解决这个问题。我在尝试将rails应用程序部署到服务器时遇到错误(ubuntu 14.04)。我使用nginx和phusion乘客来为应用程序提供服务。乘客报告以下内容:
我没有使用rvm。我已经从源头安装了红宝石。
[ 2014-11-18 17:29:16.5595 1703/7f76f0885700 agents/HelperAgent/RequestHandler.h:2306 ]: [Client 20] Cannot checkout session because a spawning error occurred. The identifier of the error is cce1b2a5. Please see earlier logs for details about the error.
App 5834 stdout:
App 5834 stderr: /usr/share/passenger/helper-scripts/rack-preloader.rb: No such file or directory - hostname
App 5834 stderr: sh: 1: env: not found
App 5834 stdout:
[ 2014-11-18 17:32:35.6801 1703/7f76f2bfa700 Pool2/Implementation.cpp:287 ]: Could not spawn process for application /var/www/app/current: An error occured while starting up the preloader.
Error ID: 414aebf5
Error details saved to: /tmp/passenger-error-ROvpCg.html
Message from application: undefined method `strip' for nil:NilClass (NoMethodError)
/var/www/app/shared/bundle/ruby/2.1.0/gems/mlanett-redis-lock-0.2.6/lib/redis-lock.rb:20:in `<class:Lock>'
/var/www/app/shared/bundle/ruby/2.1.0/gems/mlanett-redis-lock-0.2.6/lib/redis-lock.rb:6:in `<class:Redis>'
/var/www/app/shared/bundle/ruby/2.1.0/gems/mlanett-redis-lock-0.2.6/lib/redis-lock.rb:4:in `<top (required)>'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `block in require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:232:in `load_dependency'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/chewy_kiqqer-0.2.4/lib/chewy_kiqqer/worker.rb:2:in `<top (required)>'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `block in require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:232:in `load_dependency'
/var/www/app/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.7/lib/active_support/dependencies.rb:247:in `require'
/var/www/app/shared/bundle/ruby/2.1.0/gems/chewy_kiqqer-0.2.4/lib/chewy_kiqqer.rb:6:in `<top (required)>'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:76:in `require'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:72:in `each'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:72:in `block in require'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:61:in `each'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler/runtime.rb:61:in `require'
/usr/local/lib/ruby/gems/2.1.0/gems/bundler-1.7.6/lib/bundler.rb:133:in `require'
/var/www/app/releases/20141118154027/config/application.rb:7:in `<top (required)>'
/var/www/app/releases/20141118154027/config/environment.rb:2:in `require'
/var/www/app/releases/20141118154027/config/environment.rb:2:in `<top (required)>'
config.ru:3:in `require'
config.ru:3:in `block in <main>'
/var/www/app/shared/bundle/ruby/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:55:in `instance_eval'
/var/www/app/shared/bundle/ruby/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
config.ru:1:in `new'
config.ru:1:in `<main>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:112:in `eval'
/usr/share/passenger/helper-scripts/rack-preloader.rb:112:in `preload_app'
/usr/share/passenger/helper-scripts/rack-preloader.rb:158:in `<module:App>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<module:PhusionPassenger>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:28:in `<main>'