Should I user Apache or Nginx & Passenger or Mongrel for my Rails application
Asked Answered
A

3

5

I have a Ruby on Rails application that will be a CMS in way which means it's mostly DB intensive. I expect it to have decent amount of traffic so before designing I'm choosing what servers to use. Most important for me is performance.

I heard good things about Nginx and many developers in the Rails community recommends it my only concern about it was that its version is 0.8 which is Beta I believe so I was concerned about potential problems. What is your say?

Also, I want to decide between using Mongrel cluster or Phusion Passenger. What do you think?

I'm planning to user Ruby 1.9 as it has better performance that Ruby 1.8 and I will be using VPS to host my website.

My main things is performance even if it takes longer to setup one over the other.

Your opinion is highly appreciated.

Thanks,

Tam

Airliah answered 14/9, 2009 at 7:45 Comment(0)
C
9

I'd second for Passenger + Nginx. Very low memory and it's not too difficult to setup. What type of server are your deploying too? Specs? OS? I'd take that into consideration as well considering your available hardware. If you've got enough memory already, then it shouldn't be an issue whether its Passenger or Apache, just optimize and cache your app efficiently.

Clannish answered 14/9, 2009 at 14:3 Comment(4)
Thanks Omar and Nick for answering. My server will be a VPS with 512 RAM and 40GB disk space. I'm using Debian Linux on it(do you recommend another?). Do you know if Passenger works with Ruby 1.9? I couldn't find any indication of that on their website, wondering if you have tried it.Airliah
512RAM is plenty, so you'd be good with standard Passenger + Apache, however, if you want to save even more memory try Nginx. It'll make the memory footprint even smaller. And yes Passenger does work with Ruby 1.9. -=) Have fun!Clannish
One annoying thing about nginx/passenger is you need to compile everything from source as nginx doesn't support dynamically loaded modules.Werner
@Werner passenger-install-nginx-module will do it for you :) .. but it could be a problem when you'll need another functionality. Right.Pongee
M
2

Two comments: You can deploy any rails app to any of your mentioned servers, so no need to decide this once and for all now.

IMO mongrel clusters are no longer worth the trouble. Go for passenger on whatever server makes you happy.

Mohler answered 14/9, 2009 at 8:17 Comment(0)
M
2

Id recommend passenger nginx, the configs are nice and tidy plus the memory footprint is really low compared to passenger apache.

Magnetics answered 14/9, 2009 at 10:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.