EDIT: At least until there's a Phusion Passenger for Win, Apache + Mongrel is the way to go. You can use Apache + FastCGI without Mongrel, but under real loads you will get (more) zombie processes and (more) memory leaks.
You could also look at proxying to Thin in the same way as detailed below. However, I've had some instabilities with Thin on Win, even though it's appreciably quicker. AB (Apache Benchmark) is your friend here!
Configuring Apache + Mongrel on Windows is not significantly different from *nix.
Essentially, you need to proxy requests coming into Apache to Mongrel. What this boils down to is something like this:
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
<VirtualHost localhost:80>
ServerName www.myapp.comm
DocumentRoot "C:/web/myapp/public"
ProxyPass / http://www.myapp.com:3000/
ProxyPassReverse / http://www.myapp.com:3000/
ProxyPreserveHost On
</VirtualHost>
Stick this in your httpd.conf
(or httpd-vhost.conf
if you're including it).
It assumes you're going to run mongrel on port 3000, your Rails root is in C:\web\myapp
, and you'll access the app at www.myapp.com.
To run the rails app in production mode:
mongrel_rails start -p 3000 -e production
And away you go (actually mongrel defaults to port 3000 so you could skip -p 3000
if you want).
The main difference is that you cannot daemonize mongrel on Windows (i.e. make it run in the background). Instead you can install it as a service using the mongrel_service
gem.
Also, running a cluster is more complicated and you won't be able to use Capistrano. Let me know if you want more info.