Solution for: #45: why is Rails logging to ".log"?!
Watch how you log...
- kueda on May 16, 2009, 12:00 AM UTC
After trying to blame Workling for a while, I realized it was my problem. In my environment.rb, I had
I don't explicitly set RAILS_ENV in my env, so I should have had
The Lesson: always use RAILS_ENV, never ENV['RAILS_ENV'].
config.logger = Logger.new("#{RAILS_ROOT}/log/#{ENV['RAILS_ENV']}.log", 20, 1048576)
I don't explicitly set RAILS_ENV in my env, so I should have had
config.logger = Logger.new("#{RAILS_ROOT}/log/#{RAILS_ENV}.log", 20, 1048576)
The Lesson: always use RAILS_ENV, never ENV['RAILS_ENV'].