Rails routes and mod_rewrite

I have a Rails app that uses lighttpd. My app has a bunch of routes setup to handle incoming requests. Lighttpd has a set of re-write rules to convert the incoming request into calls into dispatch.fcgi. This is the default configuration.

One thing that hadn’t been made very clear to me until I went looking for it is that the lighttpd re-write rules are no longer necessary.

To get the requests into my Rails app, all I need to do is define dispatch.fcgi as my 404 handler, and any request that doesn’t exist in the file system will be handled by my Rails app.

This is fully documented here but as I said, it wasn’t obvious to me until I needed to fix it!

This entry was posted on Fri, 04 Nov 2005 21:08:00 GMT . You can follow any any response to this entry through the Atom feed. You can leave a comment or a trackback from your own site.
Tags


Trackbacks

Use the following link to trackback from your own site:
http://blog.craz8.com/trackbacks?article_id=rails-routes-and-mod_rewrite&day=04&month=11&year=2005

Comments

Leave a response

Leave a comment