feat: expose Apache logs to host for fail2ban integration
- Mount Apache logs directory to ./logs/apache - Configure JSON file logging driver with rotation - Set max log size to 10MB with 3 files retention - Enable fail2ban to monitor access logs directly - Prevents need for systemd service to export logs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -8,6 +8,13 @@ services:
|
||||
volumes:
|
||||
- ./data:/var/www/html
|
||||
- ./apache/nextcloud.conf:/etc/apache2/conf-enabled/nextcloud.conf:ro
|
||||
- ./logs/apache:/var/log/apache2
|
||||
logging:
|
||||
driver: "json-file"
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
tag: "nextcloud"
|
||||
environment:
|
||||
# Database
|
||||
- MYSQL_HOST=db
|
||||
|
||||
Reference in New Issue
Block a user