Skip to content

Instantly share code, notes, and snippets.

@jjneely
Created October 16, 2014 17:44
Show Gist options
  • Save jjneely/91c877d463681a93eac5 to your computer and use it in GitHub Desktop.
Save jjneely/91c877d463681a93eac5 to your computer and use it in GitHub Desktop.
Logrotate for Docker's stdout/stderr json dumps
# Prune Docker's JSON format stdout/stderr files as they
# grow boundlessly. Also, deal with the fact that the Docker daemin
# will not re-open these files.
/mnt/docker/containers/*/*-json.log
{
rotate 31
daily
missingok
notifempty
compress
delaycompress
copytruncate
}
@jjneely
Copy link
Author

jjneely commented Oct 16, 2014

The default path would be: /var/lib/docker/containers//-json.log

We alter the Docker container path in certain cases and this just happened to be a copy of that case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment