The Ins and Outs of Serving Rails
One of the biggest failures I found starting in Rails was the lack of a standard for hosting. In the mod_perl or php world, the standard apache distribution has everything needed built in to the standard distribution, and you’d be hard pressed to find a hosting system (of any size) that doesn’t have them.
Rails on the other hand, seemed to have a boatload of ways to serve itself. There doesn’t seem to be a “standard” webserver. You have mongrel, nginx, phusion passenger (mod_rails), lighttp… the list goes on. And it doesn’t seem that there’s an accepted “proper” way to do the webserving yet. Maybe it’s a case of different tools for different cases, maybe it’s just a symptom of a system that’s relatively young (compared to the apache/perl/php world).
Obviously the build in webserver (ruby script/server) will always be there, but if you’ve got your first app up and ready, and your hosting provider either doesn’t supply rails hosting as an option, or their setup isn’t up to the task I discovered an interesting (and most importantly, free) solution.
Check out Heroku. It’s a free, online hosting system with a fairly unique method of using git to allow you to simply run “git push” in your app directory and have any changes pushed up to their hosting cloud. Now granted, they are a commercial company and you only get the equivalent of the lowest level of hosting (a “Blossom” plan with 5mb of disk space), but this is perfectly adequate for a personal project or learning application. And again, it’s free
Dead Programmer Society has a nice write up on the whole deal.
No related posts.