Rails4, passenger, nginx (application is rails4 but wrongly detected as Rails1 or Rails2)

StackOverflow https://stackoverflow.com/questions/23210664

質問

I am deploying rails4 application with standard setup but getting:

This application is a Rails 4 application, but it was wrongly detected as a Rails 1 or Rails 2 application. This is probably a bug in Phusion Passenger, so please report it.

http://ec2-54-187-113-154.us-west-2.compute.amazonaws.com/

役に立ちましたか?

解決

Phusion Passenger assumes that Rack application (Rails >= 3) directories have a certain layout. Suppose that you have a Rack application in /webapps/rackapp. Then that folder must contain at least three entries:

* config.ru, a Rackup file for starting the Rack application. This file must contain the complete logic for initializing the application.

* public/, a folder containing public static web assets, like images and stylesheets.

* tmp/, used for restart.txt (our application restart mechanism). This will be explained in a following subsection.

So please check your having, config.ru in your root directory and public, tmp folders.

Refer: http://www.modrails.com/documentation/Users%20guide%20Nginx.html#deploying_a_rack_app

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top