Q:

Redirect example.com to rails server running on localhost:3000 leaving apache sites intact?

I am working on a rails app which runs on localhost:3000. I want example.com to point to localhost:3000. I edited the /etc/hosts file but it doesn't take port number so the request goes to apache. I want apache sites to work as they are but redirect example.com to rails server.
Please suggest the best way to achieve this.

A:

Can you just specify example.com:3000 when browsing to your site? If not, I'd suggest using Phusion Passenger so that Apache can continue to respond on port 80 while also running your app.

