meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
linux:docker:log [2024/08/01 08:59] niziaklinux:docker:log [2026/03/01 17:35] (current) niziak
Line 3: Line 3:
 Prevent disc space flooding with container logs: Prevent disc space flooding with container logs:
  
 +  * [[https://signoz.io/blog/docker-log-rotation/|Docker Log Rotation Configuration Guide | SigNoz]]
   * [[https://willsena.dev/strategies-for-rotating-docker-logs/|Strategies for Rotating Docker Logs]]   * [[https://willsena.dev/strategies-for-rotating-docker-logs/|Strategies for Rotating Docker Logs]]
   * [[https://www.paulsblog.dev/how-to-manage-docker-logfiles-with-logrotate/|How To Manage Docker Logfiles with Logrotate]]   * [[https://www.paulsblog.dev/how-to-manage-docker-logfiles-with-logrotate/|How To Manage Docker Logfiles with Logrotate]]
Line 16: Line 17:
     delaycompress     delaycompress
     copytruncate     copytruncate
 +}
 +</file>
 +
 +
 +===== apache logs =====
 +
 +<file txt /etc/logrotate.d/docker-apache>
 +/var/log/apache2/*.log {
 +  weekly
 +  missingok
 +  rotate 50
 +  dateext
 +  compress
 +  delaycompress
 +  notifempty
 +  sharedscripts
 +  postrotate
 +    cd /root/dockers \
 +      && /usr/bin/docker compose kill -s HUP dokuwiki
 +  endscript
 } }
 </file> </file>