[Mongrel-development] [ANN] Unicorn: UNIX+localhost/LAN-only Mongrel fork
ezmobius at gmail.com
Thu Feb 26 02:06:49 EST 2009
> OK, here's some thoughts leading up to what I'm probably going
> to do...
> 1. APP_ROOT/config.ru is in a pretty standardized location, good.
> 2. Most config.ru files out there (probably) don't contain
> environment-specific logic. That is, developers on their
> desktop/laptops and the production app in datacenters can
> share the same config.ru without much difficulty.
> Can somebody please confirm this assumption?
Yeah i think APP_ROOT/config.ru is the standard here. Passenger uses
it and its easy to use form rackup. heroku and ey-solo both look for
config.ru in the approot.
> 3. Unicorn-specific config options should only be needed for
> server deployments. Things for the typical developer
> on their workstation should "just work", like running
> "script/server" and "mongrel_rails" in RAILS_ROOT does
> for old Rails apps.
Yeah I think this is a better idea then my suggestion.
> This leads me to keeping the Unicorn config file separate for
> environments. My personal experience (with old Rails apps) is that
> there are multiple "production"-like environments (staging, QA,
> different datacenters)...
> I'd imagine some apps I support will end up with config file
> layouts looking like this:
> Thus to deploy to our Los Angeles datacenter, the script
> would just run:
> unicorn -c APP_ROOT/config/unicorn/prod_lax.rb
> If there's an APP_ROOT/config_prod.ru needed, then
> the APP_ROOT/config/prod_*.rb files would each
> be able to specify APP_ROOT/config_prod.ru instead
> of APP_ROOT/config.ru.
> That is, the Unicorn config file can specify an alternate
> config.ru, but config.ru cannot specify a different
> Unicorn config file.
> Am I making sense? (it's been a long week for me so far...)
I think you've nailed it here.
More information about the Mongrel-development