<p>In a project I am working on, Apache is set up to only forward requests that come in as /prefix/* to mongrel. How can I tell ruby on rails to generate all URLs with that prefix? </p>

<p>I have the routes set up for forward to the correct controller action by doing this:</p>

<pre><code>map.connect 'sfc/:controller/:action'
</code></pre>

<p>but that doesn't seem to affect the way that the url writer generates the URLs.</p>

<p>Any ideas?</p>

The
```
RAILS_RELATIVE_URL_ROOT
```
environment variable should do the trick, though I haven't tried it myself.