I have logging configured going to console and a log file. In heroku world, does it even make sense to log to a file? Is there any way I can retrive the log file?
You can view logs with the Heroku CLI, the dashboard, your logging add-on, or in your log drain.
On a Windows computer: Inside the Control Panel, find System & Security. From there, go to Administrative Tools and then the Event Viewer. Open Windows Logs and choose Application. This will show you all the application logs saved on your computer.
Simply use heroku logs to display the last 100 lines of your logs. Heroku only saves the last 1500 lines of logs, which you can access using heroku logs -n 1500 . If you want more logging, check out Heroku add-ons like Logentries or Papertrail.
Logs are streams, not files.
To access the logging stream, you simply heroku logs
and you'll see the full stream. Anything you output with your applications logger will go here.
You do not have log files.
Should you wish to capture files to frame and put on your wall, sign up for a service such as Papertrail and use the syslog drains to get your Heroku logs into there. From there they can dump to S3.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With