I am trying to write my log files while working on a rake, it works fine in development mode, but As soon as I switch to the production environment, nothing is written in the log file.
I read here
This is normal behavior and # Vontfix tickets have also been found in lighthouse.
My question: is there any way of production, what is going on while my rake work is going on? It does some crawling and runs for hours. I would like to use this command to write the log files if / log/crawler.log
output is gone in a specific log file.
ActiveRecord :: Base.logger.info "Log text"
Thanks!
The problem you are having is that the 'information' level in the rail production mode Ignores the log of.
I recommend reading it:
And make your own logger:
logger = logger. New ('logfile.log' ) Logger.info "Something Happened"
Comments
Post a Comment