feat(docker): 生产环境 DevOps 基础设施 — TLS + 备份加密 + Prometheus + Redis 持久化
新增: - nginx/nginx.conf: TLS 1.2/1.3 终端 + HSTS/CSP 安全头 + SSE 长连接 + 50M 上传限制 - prometheus/prometheus.yml: HMS/PostgreSQL/Redis/Nginx 四指标源 - prometheus/alerts.yml: 4 组告警规则(系统/应用/数据库/Redis),含 5xx 错误率 + 内存 + 连接数 - restore.sh: 备份恢复脚本(支持加密备份解密恢复) 改进: - backup.sh: 新增 BACKUP_PASSPHRASE 加密(AES-256-CBC)+ 完整性校验 + 恢复指引 - docker-compose.production.yml: 添加 Nginx/Prometheus/Grafana/uploads-backup 容器 - docker-compose.yml: Redis 添加 --appendonly yes 持久化 - .env.production.example: 添加 DevOps 相关环境变量模板
This commit is contained in:
8
docker/nginx/ssl/.gitkeep
Normal file
8
docker/nginx/ssl/.gitkeep
Normal file
@@ -0,0 +1,8 @@
|
||||
# 将 SSL 证书放置在此目录
|
||||
# 必需文件: fullchain.pem + privkey.pem
|
||||
# 生产环境建议使用 Let's Encrypt 或云服务商证书管理
|
||||
#
|
||||
# Let's Encrypt 示例:
|
||||
# certbot certonly --standalone -d your-domain.com
|
||||
# cp /etc/letsencrypt/live/your-domain.com/fullchain.pem .
|
||||
# cp /etc/letsencrypt/live/your-domain.com/privkey.pem .
|
||||
Reference in New Issue
Block a user