views:

231

answers:

3

I'm working on a Rails application and it is currently hosted on a shared hosting. However, it is getting a lot of features that requires reasonable processing and I'm thinking of move it to a VPS, clouded server. I have no experience on server management, but, since it is a simple application, I'd like to manage it myself. Googling a bit, I've found a couple of setup options:

  • Phusion Passenger + Apache. This seems to be the default option today.
  • Phusion Passenger + Nginx. Nginx presents itself as lighter option to Apache, but the latter has much more modules and support.
  • Mongrel + Apache. I don't know what to think about Mongrel; the discussions I've found seem to be outdated, but there is a nice article about a cluster of Mongrels with Apache.

So what do you recommend? The application has a light traffic, but performs a lot of processing-intensive operations and serves only a few static files. Memory consumption is important, because on VPS they bill accordingly the memory you need. And, as I am a beginner, documentation and ease of configuration is crucial. It would be nice too if the server had some kind of Comet/server-pushing support; I'm planning to add it soon (I cannot stand the nasty idea of pooling).

+3  A: 
Tomh
Unless there are some specific Apache modules you require, I would second this option. Nginx is much simpler to configure than Apache. Nginx does have a decent number of modules. Installation is a breeze, too. When you install the passenger gem it will compile and install Nginx for you.
The Who
+2  A: 

I'd go with nginx as well. I've used Apache/Passenger and nginx/Passenger on a VPS and memory usage was better with nginx. I didn't do any benchmarks with my particular app, but nginx just feels faster.

One thing to note about installing and configuring nginx - you need to choose your modules at compile time unlike Apache where you can configure modules at runtime.

Andy Gaskell
+1  A: 

I have had no problems with Apache. Very smooth. No speed issues or memory problems on my end. Really depends on what you're more familiar with or what your spec requirements are. Engineyard runs on Nginx though and I've also had a positive experience running with that as well.

Lukas