The long-awaited mod_rails for apache was released yesterday by Phusion, a Netherlands based IT company. As many of you have already done, I hopped on board to see how it worked and was amazed on how easy it was to get up and going.
Ryan Bates, a guy whose voice many of us Rails coders have grown to know and love, assisted the Phusion team in creating a short screencast on how to install Passenger onto your Mac.
It was basically 3 steps:
1. Install the RubyGem
2. Run the passenger installer script
3. Modify your apache conf file to include the new virtual host
Can it really get easier than that? I submit that it can not.
In my opinion, Passenger is filling a void that has haunted the Ruby on Rails community for some time. Matz is quoted as saying “It is often said that Rails is weak on deployment; PHP runs fairly fast just by uploading scripts. Rails is slow on development mode, and requires restarting on production mode (and bit complex to configure). modrails might be the answer for it.”.
To get Passenger, go to http://www.modrails.com


>Can it really get easier than that? I submit that it can not.
It might be easier to just run one application that does all 3 steps for you =)
Unfortunately, it turns out that it's not quite this easy.
I don't remember if Ryan said anything about Mac in his screencast, but I don't think he was using a Mac. Why? Because when I ran the apache module install script on my Mac, I got a message saying that there are problems with the Apache2 that comes installed on the Mac and that I should install another copy of Apache2 myself!
The message did say that I could still install the module for Mac's Apache, but that I might have problems. Well, I was just trying this to play with a little, so I went ahead and tried that. But, the compile failed. Phooey.
So, I bagged it for now. I didn't have much time when I tried it, but I'll come back to it at some point. I do think it's a great idea. But I saw your post and wanted to point out that it's not quite Mac-friendly yet... ironic, considering that the vast majority of Rails developers use Macs.
Ben: Ryan was using a Mac. But he installed Apache from MacPorts.
We tried making Passenger work on the default Apache on OS X. But eventually we gave up: OS X's default Apache just seems to be broken for reasons that we can't find out.
Unfortunately this problem is completely beyond our power. This leaves us no choice but to warn people not to use the default Apache.
I don't think you should really mind if you can't get this working on your Mac - it's for production use isn't it?
I've just spent a couple of hours playing with this so that we can get it working nicely with the Ensim control panel on our servers. It works well and now we'll be able to offer shared rails hosting, where as we haven't been able to previously!
Thanks very much to the guys at phusion!
Ok, one thing that you really need is you have an already functioning apache2 in your box. I tried the exact three step on my ubuntu box. It runs. It works. Rails in cheap hosting is a reality now.
I wonder how long it will take for shared hosting providers to start supporting mod_rails. I've wanted to be able to use a few Rails apps (e.g. Radiant CMS) to power a smallish web site on a shared hosting account but haven't had much luck with that to date.
I have tried it and was pretty impressed, simple helloworld stuff was running at about 2 millisecond/request when tested with apache bench.
but still learning and exploring how to make it run concurrently, as when testing with ab with concurrent requests, performance started degrading
CohesiveFT now offers Passenger among web container options for your Rails 2 applications, in addition to nginx, lighttpd and mongrel. Check it out at http://es.cohesiveft.com/site/rails2