问题已更新,请阅读UPD2。
我正在尝试通过 Passenger Nginx 模块部署应用程序DS710+(已安装 ruby 1.9.2p0)。与 has_and_belongs_to_many_association.rb 文件相关的语法错误。请查看屏幕截图(已删除,问题已更新)。我很确定问题不在库文件中。应用程序通过 webrick 运行良好。您能否建议要查找什么?
UPD1
ruby-v
ruby 1.9.2p0 (2010-08-18 revision 29036) [i686-linux]
宝石列表-d 乘客
*** LOCAL GEMS ***
passenger (3.0.6)
Author: Phusion - http://www.phusion.nl/
Rubyforge: http://rubyforge.org/projects/passenger
Homepage: http://www.modrails.com/
Installed at: /usr/lib/ruby/gems/1.9.1
Easy and robust Ruby web application deployment
UPD2
我决定重新安装所有东西。它解决了之前的问题,但又引发了另一个问题。错误是:The application spawner server exited unexpectedly: Unexpected end-of-file detected.
这是截屏。
新输出:
ruby-v
ruby 1.9.2p180 (2011-02-18 revision 30909) [x86_64-linux]
宝石列表-d 乘客
*** LOCAL GEMS ***
passenger (3.0.7)
Author: Phusion - http://www.phusion.nl/
Rubyforge: http://rubyforge.org/projects/passenger
Homepage: http://www.modrails.com/
Installed at: /usr/lib/ruby/gems/1.9.1
Nginx 错误日志:
[ pid=5653 thr=32771 file=ext/common/Watchdog.cpp:128 time=2011-04-20 14:08:34.505 ]: waitpid() on Phusion Passenger helper agent return -1 with errno = ECHILD, falling back to kill polling
[ pid=5654 thr=49156 file=ext/common/Watchdog.cpp:128 time=2011-04-20 14:08:34.506 ]: waitpid() on Phusion Passenger logging agent return -1 with errno = ECHILD, falling back to kill polling
2011/04/20 14:12:33 [notice] 7614#0: signal process started
答案1
您说您已经安装了 Ruby 1.9.2p0,但是您的屏幕截图暗示 Passenger 正在使用 1.9.1(Rails 不支持);请检查您的 nginx Passenger 配置,特别是该passenger_ruby
行。