Multiple rails apps on a single host with mod_rails

Hi

I’m playing around with setting up a server to host multiple rails
applications on a single hostname.

The documentation only explains how to do it using multiple virtual
hosts and i can not figure out if it is even possible.

Have you played around with a setup like this?

Mick

Mick, I haven’t, but there’s no reason you couldn’t set rewrite rules
so that this works… i.e. something like:

www.foo.com/one/ => application one
www.foo.com/two/ => application two

But you can’t have “www.foo.com” go to multiple applications, because
how would it know which one to use? (well, ok, you could do some fancy
stuff like incoming IP filtering, but I suspect this isn’t what you
are talking about).

Read up about mod_rewrite in apache. In fact, I’ve seen some other
posts in the past where someone was setting up apache to do the
equivalent of “www.foo.com/one/” => some rails app. So it shouldn’t be
too hard to extend that so that you can have multiple apps. Or maybe
you use proxy rules to proxy from apache to mongrel.

Just some thoughts…

-Danimal