PDA

View Full Version : Rails deployment question


fm75
July 27th, 2008, 11:56 AM
Hi all,

I have deployed a plain RoR app to get familiar with the OCS platform:
1) Installed the app in $HOME/rails_apps
2) Set up in the cpanel
3) Started the application

Everything worked.
The rails welcome page shows up at http://www.mydomain (even without setting up a rewrite)

Then I deleted the app from the cpanel and I started having 503 Service unavailable messages.

What I expected here is my old index.html in public_html to be displayed.

Actually, that was what I expected even when the rails application was running without setting up a rewrite.

Now, the question is: how can I make OCS serve again files from my public_html directory?

I have removed all references to the rails app in cpanel, and I have even rm -rf the app from my home directory, but I still have 503 errors.

Why the rails app worked even without setting up rewrite rules?

Maybe I missed some steps.

Thank you for your help.
FM

rob
July 29th, 2008, 01:31 AM
Check and see if you have an .htaccess file in your public_html folder. Via SSH a normal "ls" command won't show it, you have to do "ls -la" to see it. Some FTP clients require you to turn on hidden files or similar. If you do have this file, delete it. This should restore normal page serving.

The Rails app likely didn't work right away, you may have been seeing the index.html file that comes by default in the public directory of a Rails application.

fm75
July 29th, 2008, 09:30 AM
Bingo.
I didn't noticed the .htaccess file.

Thank you for your help.