Topic: Production Env Issue: Ubuntu Mongrel + Apache proxy using Capistrano

Hi Everyone,
Context:

I am building a ruby on rails app. After I successfully built and tested it in development environment, I used Capistrano to deploy it to a different machine with pretty much same configuration. The server is a Ubuntu linux box running Apache 2 and mongrel cluster. The application is deployed using Capistrano.

Issue:
Even if I shut down mongrel cluster, and I open the root url of my site in a browser (e.g www.mywebsite.com), apache still serves up content . I don't know where it is getting it from. It seems like a cached version. I'm expecting it to give me an error saying that Mongrel is down (or something like that)

Similarly, when mongrel cluster is running, and I open the root url in browser, still the STALE content is served rather than newer content (which I know should be displayed).
I want www.mywebsite.com to use routing to get data from www.mywebsite.com/mycontroller/myaction

If I open the complete url (including controller and action), then correct content is served up. Note that this problem happens only in Production environment.

Earlier I thought this was a routing error. But I've made sure that correct routing is in place. Any pointers/help is really appreciated.

Thanks
Navneet

Re: Production Env Issue: Ubuntu Mongrel + Apache proxy using Capistrano

A note on caching - it only works in the production environment.  It sounds like it is a caching issue that you are experiencing (clear your sites cache then check if it still serves up static content).

As for apache serving up content even when mongrel is down - that is strange.  It should complain when it tries to push the request to the proxy server and the proxy does not respond.  Unless it is setup to serve the static html files (as it probably is).

Charles
http://www.forthecode.com