Apache proxy + lighttpd + rails


#1

Hi list,

I’m having another problem deploying my Rails application. I set up
the servers and apache2 configuration using the excellent essay by
Duncan Davidson:
http://duncandavidson.com/essay/2006/01/railsonapache

However, he describes proxying using a subdomain. What if I want to
proxy the requests of www.domain.com/railsapp/ to
www.domain.com:8888/ and reverse it back the correct way?

The first part works, the requests are successfully routed to
www.domain.com:8888/admin/login for example. But the actual relative
urls are wrong in the rails app. They, for example, point to
www.domain.com/admin/login, instead of
www.domain.com/railsapp/admin/login wich renders in a 404, because
apache of course doesn’t know of the www.domain.com/admin url

Is there an easy way to do this correctly trough apache2? Or should I
set some var in my Rails app to append /railsapp/ to every
link/uri/stylesheet_link etc.

Many thanks in advance,