From the Mongrel website
Mongrel is a fast HTTP library and server for Ruby that is intended for hosting Ruby web applications of any kind using plain HTTP rather than FastCGI or SCGI. It is framework agnostic and already supports Ruby On Rails, Og+Nitro, and Camping frameworks.
One of the nice thing about Mongrel is that it can be easily installed as a service on Windows using the Win32 Utils library
Mongrel is packaged as a gem and depends on the win32-service gem.
$ gem install win32-service (pick the most recent one)
$ gem install mongrel (pick the win32 pre-built)
After installation you can easily start rails-applications or install a rails-application as a service.
This first sample creates a new rails application and uses Mongrel to serve it in production-mode on port 9000.
$ rails newapp
$ cd newapp
$ mongrel_rails start -e production -p 9000
This second sample creates a new rails application and installes it as a service with the name rails_newapp
$ c:
$ rails newapp
$ mongrel_rails_service install -n rails_newapp -r c:\newapp -p 4000 -e production
The service can now be started either from the services control panel or by writing this on the command line
$ mongrel_rails_service start -n rails_newapp
When running Mongrel as a service you have to think about what permissions the service is going to get. If the service doesn’t have write-access to the log-files in the gem’s bin-directory (something like:
C:\ruby\lib\ruby\gems\1.8\gems\mongrel-0.3.12.4-mswin32\bin) it won’t be able to start and you won’t get any log files that tells you why.
From the Mongrel website
Mongrel is a fast HTTP library and server for Ruby that is intended for hosting Ruby web applications of any kind using plain HTTP rather than FastCGI or SCGI. It is framework agnostic and already supports Ruby On Rails, Og+Nitro, and Camping frameworks.
One of the nice thing about Mongrel is that it can be easily installed as a service on Windows using the Win32 Utils library
Mongrel is packaged as a gem and depends on the win32-service gem.
$ gem install win32-service (pick the most recent one)
$ gem install mongrel (pick the win32 pre-built)
After installation you can easily start rails-applications or install a rails-application as a service.
This first sample creates a new rails application and uses Mongrel to serve it in production-mode on port 9000.
$ rails newapp
$ cd newapp
$ mongrel_rails start -e production -p 9000
This second sample creates a new rails application and installes it as a service with the name rails_newapp
$ c:
$ rails newapp
$ mongrel_rails_service install -n rails_newapp -r c:\newapp -p 4000 -e production
The service can now be started either from the services control panel or by writing this on the command line
$ mongrel_rails_service start -n rails_newapp
When running Mongrel as a service you have to think about what permissions the service is going to get. If the service doesn’t have write-access to the log-files in the gem’s bin-directory (something like:
C:\ruby\lib\ruby\gems\1.8\gems\mongrel-0.3.12.4-mswin32\bin) it won’t be able to start and you won’t get any log files that tells you why.