# Best platform for production deployment of RoR applications

**URL:** <https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113>\
**Category:** Rails\
**Created:** [March 26, 2007, 3:46am UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113 "2007-03-26T03:46:40Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![David\_JSOrman](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b3f665/32.png) [@David\_JSOrman](https://www.ruby-forum.com/u/David_JSOrman)\
**Post date:** [March 26, 2007, 3:46am UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113/1 "2007-03-26T03:46:40Z")

</div>

Hi,

I’m going to be setting up a small server farm for my production RoR  
application deployments. I’m now at the point I need to pick what  
software I’ll be running/management techniques.

So, my question is, what OS (and if Linux, which distribution) are  
most people having the best luck/performance with? I’m well versed in  
FreeBSD/Linux/Solaris, and would be open to other options as well.

Now, once the OS decision is made, how are people managing Ruby?  
Installing it by hand (compiling/etc), and then using gems to keep  
things updated? Or using the built-in distribution copies (IE debs or  
ports or whatever)? I was thinking doing it by hand might be better so  
as to keep current with bug fixes and security updates. In this case,  
I’d be using KVM with linux to create virtual machines, and install  
ruby/rails inside the virtual machines, that way I can build once and  
simply deploy the virtual machines across the server farm easily. Does  
this make sense?

Now, as to development, soon there will be a team working on RoR  
applications. Is the “best” (I realize this is opinion based as much  
as fact) multi-user development something like SVN? Or is there some  
better solution?

Now, finally, after development, what is the best way to deploy? After  
initial deployment, best way to deploy updates?

> From reading documentation, it looks like mongrel is the best  
> application server, and with the updates to the proxy functionality  
> (coming in next release), lighttpd is the best front end. This is what  
> I was _planning_ on. I was also thinking about going with Ubuntu  
> (since 7.x is going to have KVM integrated) for the OS.

I’ve been using Solaris on my servers, but I’ve gotten pretty fed up  
with the update/patching system, and the fact that it takes a fair  
amount of fuss to get a lot of applications to work, so that’s why I’m  
evaluating switching to Linux, simply from the “ease of use”  
standpoint. FreeBSD was an option, but jails just seem kinda “hackish”  
to me, at least in terms of administration. KVM seems to be the  
closest to Solaris Zones I’ve been able to find.

Well, I really do appreciate any input/comments/opinions you all could  
provide. Some of this might be in documentation I missed, if so - feel  
free to just tell me so (and I’d REALLY appreciate links.) Everything  
else, I’m open to hearing any/all ideas. 🙂

Thank you kindly,  
David J. Orman

---

<div class="post-metadata">

**Author:** ![David\_JSOrman](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b3f665/32.png) [@David\_JSOrman](https://www.ruby-forum.com/u/David_JSOrman)\
**Post date:** [March 26, 2007, 7:30am UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113/2 "2007-03-26T07:30:56Z")

</div>

Apache 2.2 or 2.3 is in favor as the webserver of choice. There are  
lots of tutorials out there on using mod\_proxy\_balancer and that’s  
what I just finished deploying my application on.

Check out Capistrano for pushing your app to multiple servers.

As far as OS/distros go, there’s lots of support/tutorials out there  
for Linux I’m only running a single front-end server right now, so I  
don’t have any experience with virtual machines, but I would imagine  
any distro would do fine. RedHat variants are probably the most  
widely used, so if lots of tutorials and such are important to you,  
then RedHat might be the way to go. But it sounds like you have a  
compelling reason to go with Ubuntu, so that might outweigh any  
benefit of a large user community on RedHat.

Good Luck!

---

<div class="post-metadata">

**Author:** ![David\_JSOrman](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b3f665/32.png) [@David\_JSOrman](https://www.ruby-forum.com/u/David_JSOrman)\
**Post date:** [March 26, 2007, 9:55am UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113/3 "2007-03-26T09:55:34Z")

</div>

There’s now a Google Group dedicated to Ruby on Rails deployment  
discussions called “Deploying Rails” or “rubyonrails-deployment” if you  
want to ask your question there.

David J. Orman wrote:

> Hi,
> 
> I’m going to be setting up a small server farm for my production RoR  
> application deployments. I’m now at the point I need to pick what  
> software I’ll be running/management techniques.
> 
> So, my question is, what OS (and if Linux, which distribution) are  
> most people having the best luck/performance with? I’m well versed in  
> FreeBSD/Linux/Solaris, and would be open to other options as well.

My current preference is Ubuntu 6.06 LTS Server. I wanted something more  
up-to-date than RHEL/CentOS at the time I was deciding but was also  
going to have security patches available for longer than something like  
Fedora Core. This was my first Debian-based distribution having been a  
long time Red Hat user and have so far enjoyed using apt-get/dpkg over  
rpm/up2date/yum/etc.

> Now, once the OS decision is made, how are people managing Ruby?  
> Installing it by hand (compiling/etc), and then using gems to keep  
> things updated? Or using the built-in distribution copies (IE debs or  
> ports or whatever)? I was thinking doing it by hand might be better so  
> as to keep current with bug fixes and security updates. In this case,  
> I’d be using KVM with linux to create virtual machines, and install  
> ruby/rails inside the virtual machines, that way I can build once and  
> simply deploy the virtual machines across the server farm easily. Does  
> this make sense?

My preference is to compile from source all the critical components in  
my system where I need to have control over how they are built or how  
frequently they are updated which in this case would be Ruby, Apache,  
and MySQL (Rails is handled through gem).

One problem with using distribution packages is that the packager has  
decided for you what options are compiled or not compiled into the  
package. And then if you don’t like those options and want to compile  
things from scratch that can break all sorts of other dependencies  
unless you build the package exactly as the distribution does it which  
of course is never the same as what the defaults are if you just do a  
./configure, make, make install.

Building stuff from source means more admin work, of course, since you  
can’t just keep everything updated with some simple package commands  
(apt-get update, apt-get upgrade, etc.)

> Now, as to development, soon there will be a team working on RoR  
> applications. Is the “best” (I realize this is opinion based as much  
> as fact) multi-user development something like SVN? Or is there some  
> better solution?

svn is the standard choice now, though Mercurial looks interesting for  
those who need a more distributed revision control system. OpenSolaris,  
for example, picked that recently as their source code control system.  
Also you need to consider any integration between your SCCS the other  
development tools in your pipeline like your text editors/IDEs and issue  
tracking system. svn is widely supported but others like Mercurial not  
as much.

> Now, finally, after development, what is the best way to deploy? After  
> initial deployment, best way to deploy updates?
> 
> > From reading documentation, it looks like mongrel is the best  
> > application server, and with the updates to the proxy functionality  
> > (coming in next release), lighttpd is the best front end. This is what  
> > I was _planning_ on. I was also thinking about going with Ubuntu  
> > (since 7.x is going to have KVM integrated) for the OS.

I’m using the current generally recommended setup of a Mongrel cluster  
behind Apache 2.2 with mod\_proxy\_balancer. I went straight to that setup  
rather than testing out some of the other options (lighttpd + FastCGI,  
etc.) so I can’t compare and contrast the various options but I’m happy  
with what I’m using now.

–  
Michael W.

---

<div class="post-metadata">

**Author:** ![David\_JSOrman](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b3f665/32.png) [@David\_JSOrman](https://www.ruby-forum.com/u/David_JSOrman)\
**Post date:** [March 26, 2007, 8:33pm UTC](https://www.ruby-forum.com/t/best-platform-for-production-deployment-of-ror-applications/90113/4 "2007-03-26T20:33:21Z")

</div>

Hi~

On Mar 25, 2007, at 6:45 PM, David J. Orman wrote:

> Hi,
> 
> I’m going to be setting up a small server farm for my production RoR  
> application deployments. I’m now at the point I need to pick what  
> software I’ll be running/management techniques.
> 
> So, my question is, what OS (and if Linux, which distribution) are  
> most people having the best luck/performance with? I’m well versed in  
> FreeBSD/Linux/Solaris, and would be open to other options as well.

gentoo or ubuntu server linux

> Now, once the OS decision is made, how are people managing Ruby?  
> Installing it by hand (compiling/etc), and then using gems to keep  
> things updated? Or using the built-in distribution copies (IE debs or  
> ports or whatever)? I was thinking doing it by hand might be better so  
> as to keep current with bug fixes and security updates. In this case,  
> I’d be using KVM with linux to create virtual machines, and install  
> ruby/rails inside the virtual machines, that way I can build once and  
> simply deploy the virtual machines across the server farm easily. Does  
> this make sense?

on gentoo I build everythign from portage gentoo usually gets the  
latest releases of ruby within a day of them being released. On  
ubuntu I compile ruby from source but use checkinstall to tell apt  
about it.

> Now, as to development, soon there will be a team working on RoR  
> applications. Is the “best” (I realize this is opinion based as much  
> as fact) multi-user development something like SVN? Or is there some  
> better solution?

SVN is the standard scm that everyone uses with rails.

> Now, finally, after development, what is the best way to deploy? After  
> initial deployment, best way to deploy updates?

capistrano

> > From reading documentation, it looks like mongrel is the best  
> > application server, and with the updates to the proxy functionality  
> > (coming in next release), lighttpd is the best front end. This is what  
> > I was _planning_ on. I was also thinking about going with Ubuntu  
> > (since 7.x is going to have KVM integrated) for the OS.

Nginx is a much better option for the front end webserver then lighty  
or apache. Nginx beats bot lighty and apache at most benchmarks and  
it uses way less resources then either apache or lighty. I have  
hundreds of virtual machines running with nginx + mongrel\_cluster and  
it is the best way to go imho.

> I’ve been using Solaris on my servers, but I’ve gotten pretty fed up  
> with the update/patching system, and the fact that it takes a fair  
> amount of fuss to get a lot of applications to work, so that’s why I’m  
> evaluating switching to Linux, simply from the “ease of use”  
> standpoint. FreeBSD was an option, but jails just seem kinda “hackish”  
> to me, at least in terms of administration. KVM seems to be the  
> closest to Solaris Zones I’ve been able to find.

I personally prefer Xen on linux. It’s the performance leader for  
open source virtualization.

> Well, I really do appreciate any input/comments/opinions you all could  
> provide. Some of this might be in documentation I missed, if so - feel  
> free to just tell me so (and I’d REALLY appreciate links.) Everything  
> else, I’m open to hearing any/all ideas. 🙂
> 
> Thank you kindly,  
> David J. Orman

Good luck with building out your server farm. Virtualization is  
definitely the way to go.

Cheers-  
– Ezra Z.  
– Lead Rails Evangelist  
– removed\_email\_address@domain.invalid  
– Engine Y., Serious Rails Hosting  
– (866) 518-YARD (9273)
