Rails port on Apache Passenger

Hi everyone!

I have managed to successfuly install Rails port application (following this: http://wiki.openstreetmap.org/wiki/The_Rails_Port tutorial. When I run it under WEBRick server, it runs ok and i can access api. However I cannot make it run under Apache Passenger. Accessing any page I get following error:

Your application’s database configuration file might be written incorrectly. Please check it and fix any errors. The database server may not be running. Please check whether it’s running, and start it if it isn’t.

Error message:
PG::Error: ERROR: relation “oauth_tokens” does not exist LINE 5: WHERE a.attrelid = ‘“oauth_tokens”’::regclass ^ : SELECT a.attname, format_type(a.atttypid, a.atttypmod), pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod FROM pg_attribute a LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum WHERE a.attrelid = ‘“oauth_tokens”’::regclass AND a.attnum > 0 AND NOT a.attisdropped ORDER BY a.attnum (ActiveRecord::StatementInvalid)

Exception class:
ActiveRecord::StatementInvalid

Its weird, because under WEBRick server it works. Can anyone help me solve this issue? I am using Debian 6.

thanks!

Nobody has any suggestions? Any help would be appreciated.

Try to ask at help.osm.org … or even better at the OSM mailing list about development

http://wiki.openstreetmap.org/wiki/Mailing_lists

thanks, I managed to repair production osm database (i needed to run gem install builder before creating database).

Now i have a new problem. I still cannot access Rails port application on Apache. I am getting OSM error page with error code 500. Apache log reveals two errors:

  1. ActionView::Template::Error (index.js isn’t precompiled)
  2. ActionController::RoutingError (No route matches [GET] “/assets/osm_logo.png”)

FIgured it out. Assets need to be precompiled in production mode, therefore it works in WEBrick but not in Apache Passenger