我正在尝试将我的rails应用程序置于生产模式,或者至少删除rails生成的错误堆栈。
这是我目前的设置
Apache - >乘客 - > Rails App
应用程序在开发模式下工作正常,但是当我更改" RailsEnv"在Apache生产,乘客给我下面的错误显示。我试过重启Apache
Web application could not be started
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected ':', expecting =>
...oster["User_Meta"] = {"__type":"Pointer","className":"User_M...
... ^
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected ',', expecting keyword_end
...r_Meta"] = {"__type":"Pointer","className":"User_Meta","obje...
... ^
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected ':', expecting keyword_end
..."__type":"Pointer","className":"User_Meta","objectId":"actua...
... ^
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected ',', expecting keyword_end
...inter","className":"User_Meta","objectId":"actualObjectIdHer...
... ^
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected ':', expecting keyword_end
...ssName":"User_Meta","objectId":"actualObjectIdHere"}
... ^
/var/vhost/dev/sensori/app/controllers/_roster_controller.rb:15: syntax error, unexpected '}', expecting keyword_end (SyntaxError)
答案 0 :(得分:1)
看起来您的应用程序是在Ruby 1.8中运行的,尽管您的应用程序是使用Ruby 1.9语法编写的,因此它失败了。仔细检查您的PassengerRuby设置是否指向您要使用的Ruby解释器。