How practical is it to run a Rails server with Apache or Nginx even in development mode?
Since WEBrick or Mongrel might be limited to not having keep-alive
etc, can't Apache or Nginx be used with Rails even in development mode?
For example, running Apache there开发者_开发知识库 always, and attach Rails to it, so that starting Rails meaning starting the Rails part, and no webserver such as WEBrick or Mongrel need to be started. Is that feasible? On some Mac, even Apache is running all the time when the system Settings has the "Web sharing" selected.
You can use Apache or nginx or any server of your choice for any environment you wish to run. But you can't just start it with rails server
.
As described in this post, you just need to set the right option in your httpd.conf
, in the section that serves your rails:
## Specify Rails Environment here, default value is "production" RailsEnv development
精彩评论