Enable local driver for log rotation #234
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #231. For this PR, I verified that on the QA server...
docker-compose logs service
outputs logssudo docker ps -qa | sudo xargs docker inspect --format='{{.LogPath}}' | sudo xargs ls -hl
shows a reduction in log sizedocker inspect <container>
shows max-file as a configAs detailed at https://docs.docker.com/config/containers/logging/local/#options, this defaults to a 20M file for each log and 5 maximum files (each compressed).
In a 3 month period, we expect 15MB for service and 640MB for nginx for a very active server, so the defaults for 100MB for service (because it's less stuff in docker-compose) and 600MB for nginx seem like good conservative defaults. We can dial the latter down if necessary.
This risk of this PR is that we are possibly throwing away old logs and someone might find that objectionable.