What are the pros and cons of using Nginx over Apache with Rails when using Passenger

Passenger recently got support for Nginx, what are the pros and cons of it over Apache as a web server for Rails applications?


Solution 1:

Nginx is far more lightweight, taking up less memory and other resources. On the other hand, Apache has more esoteric modules, built-in support for many more things, and is more widely used, both in general (so more docs and blog posts on using it for different tasks) and with Passenger (and so more of the kinks will have been found and fixed already).

On a more subjective level, I find nginx's config file format to be easier to work with and it's request processing model more intuitive.