Hello,
I googled around the internet for a while, but cannot seem to find any
answer to my problem. Hell, I cannot even find anyone having it ;) I
suppose this discussion board will be the best to ask for advice, as I
think it is related to the passenger mod.
I have a multisite app written in Rails. The code for the app is
physically the same, sitting in /rails/myapp. The domains,
example.com
and
else.org, point (apache DocumentRoot) to /rails/myapp/sites/
example.com/public and /rails/myapp/sites/
else.org/public, as
expected. It works.
Now I would like to have the first one in the production environment
and the other in development. So I set in the apache2 config for
example.com "RailsEnv production", for
else.org "RailsEnv
development". Reloaded apache and it does not seem to work as I would
expect it to.
Despite having the latter in "development" (raise RAILS_ENV puts it on
screen), what it looks like is a "production". Everything is logged
into "production.log" and the template caching is active, regardless
of which site I use. This happens if I use both sites at the same
time. If I wait long enough (probably until sessions expire) and use
the "development" site only, everything works fine in "development"
environment... except that as soon as someone opens the production
site, I switch back to the production mode with the other site as
well.
What do I do wrong? Is it at all possible with passenger to run the
same app (PassengerAppRoot) in two different environments from two
different sites? Should I adjust some passenger caching, or is it the
matter of rails and I should look for help elsewhere?
I would gladly appreciate an answer.
Apologies for my imperfect English, not a native speaker ;)
Thanks in advance,
Sorrow.