Question

App Platform Logs - Retrieve past run errors

I have been running a node.js app using the App Platform since last year. I am having occasional errors from users submitting information which I have been able to see through log messages (through the control panel).

An app crashed about a week ago (25 March) and DO automatically re-deployed/re-started the app (same deployment id). Since the app was restarted, I have been unable to view the crash log (pre-25 March) or previous normal log activity, and it appears these have been overwritten with new normal log activity from post-25 march.

Note that my last deployment of this was on 1 March (same deployment id). I have been unable to view any logs on the same deployment ID between 1 March and 25 March.

How can I go back to view the crash log details from 25 March? Through the control panel and doctl I can only view post-25 March logs.


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Accepted Answer

Hi there,

I believe that the run logs are only stored to stdout and stderr so once the container is redeployed the logs are cleared out.

I’ve seen a similar question here, where a community member was looking for a way to retain the logs:

https://www.digitalocean.com/community/questions/how-can-app-platform-container-logs-be-retained

I believe that according to the accepted answer, this is not supported currently, but this is something that is being considered for the future.

There is also another suggestion for a community member saying that they’ve decided to use supervisord and store the logs into a file, then transported those log files to a remote syslog server via https://github.com/papertrail/remote_syslog2 in run_command before launching Docker Entrypoint.

Regards, Bobby