Files
tilbudgivern/scripts/rotate-logs.sh
alexpolo1 9d1b1917a7 Add comprehensive database backup setup and scripts
- Created DATABASE_BACKUP_SETUP.md for detailed backup instructions
- Implemented backup-databases.sh for automated database backups
- Added logrotate configuration for managing backup logs
- Developed setup scripts for user-specific backup configurations
- Included error handling and logging in backup processes
- Established cron job setup for automated backups
- Provided examples and troubleshooting tips in documentation
2025-11-16 21:12:29 +00:00

13 lines
410 B
Bash

#!/bin/bash
# Local logrotate script for tilbudgivern backups
# Can be run manually or via crontab as alex user
LOGROTATE_CONFIG="/mnt/HC_Volume_103713257/tilbudgivern/infra/logrotate.conf"
STATE_DIR="/mnt/HC_Volume_103713257/tilbudgivern/logs/logrotate-state"
# Create state directory if it doesn't exist
mkdir -p "$STATE_DIR"
# Run logrotate
/usr/sbin/logrotate -s "$STATE_DIR/status" "$LOGROTATE_CONFIG"