Logging drivers and log rotation
Select an icon to see what it is.
Step 4 of 6
local: a compact format with rotation built in
The local driver stores logs in a more compact format than json-file and rotates them by default. docker logs reads it as usual. Its files are for Docker to read, not for other tools to parse, so use json-file if something else reads the files.
$ docker run -d --log-driver local nginx/var/lib/docker/containers/c5d6e7f8091a2b3cc5d6e7f8091a2b3cc5d6e7f8091a2b3cc5d6e7f8091a2b3c/local-logs/
container.log (compact format, rotated by default)