Hey All, I can''t seem to find a straight answer, but I was wondering if someone could provide me with a simple explanation of switching to the production environment. It looks like I could just alter environments.rb under /config, but that seems like a hack. How would I go about getting my application running in the production environment? Cheers, Eric Czarny eczarny@stonehill.edu
On Feb 21, 2006, at 10:25 AM, Eric Czarny wrote:> I can''t seem to find a straight answer, but I was wondering if > someone could provide me with a simple explanation of switching to > the production environment. It looks like I could just alter > environments.rb under /config, but that seems like a hack. How > would I go about getting my application running in the production > environment?Uncomment this line in environment.rb: # ENV[''RAILS_ENV''] ||= ''production'' Then, you can set the RAILS_ENV environment variable before starting the application. -- -- Tom Mornini
As is mentioned in the very environment.rb, set it in your app/web server. SCGI has an environment setting in its YAML config. WEBrick has a command line option (not that you''d want to really use it for full-on production). Joe -- Posted via http://www.ruby-forum.com/.