chore: 针对备份及还原处理

This commit is contained in:
2025-11-15 16:15:58 +08:00
parent cbc4529a34
commit c0252a2dd2
21 changed files with 4618 additions and 44 deletions

View File

@@ -0,0 +1,21 @@
# 备份配置
BACKUP_NAME="server-production"
BACKUP_SOURCE="/var/www/html /etc/nginx"
BACKUP_DEST="/backups"
# 数据库配置
DB_HOST="localhost"
DB_USER="backup_user"
DB_PASSWORD="secure_password"
# 通知配置
SLACK_WEBHOOK="https://hooks.slack.com/services/..."
EMAIL_TO="admin@company.com"
# 加密配置
ENCRYPTION_KEY_PATH="/etc/backup/keys"
GPG_PASSPHRASE="your_secure_passphrase"
# 长路径支持
LONG_PATH_SUPPORT="true"
TAR_OPTIONS="--force-local"