Compare commits

...

3 Commits

Author SHA1 Message Date
Cauê Faleiros
31b59bb696 chore(ops): update mysql backup volume path
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 2m20s
2026-03-25 16:28:39 -03:00
Cauê Faleiros
03a0809c6a feat(ops): add mysql backup service to docker compose
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 8m15s
2026-03-25 15:57:46 -03:00
Cauê Faleiros
07be06d258 fix: remove storage/test_write from git tracking 2026-02-19 09:41:54 -03:00
2 changed files with 26 additions and 12 deletions

View File

@@ -5,7 +5,6 @@ version: "3.7"
########################################################## ##########################################################
services: services:
# ===== KRAYIN CRM ===== # ===== KRAYIN CRM =====
crm: crm:
image: gitea.blyzer.com.br/blyzer/growup-crm:latest image: gitea.blyzer.com.br/blyzer/growup-crm:latest
@@ -61,7 +60,7 @@ services:
- node.role == manager - node.role == manager
resources: resources:
limits: limits:
cpus: '1' cpus: "1"
memory: 1024M memory: 1024M
command: command:
[ [
@@ -71,20 +70,35 @@ services:
"--default-authentication-plugin=mysql_native_password", "--default-authentication-plugin=mysql_native_password",
"--max-allowed-packet=512MB", "--max-allowed-packet=512MB",
"--expire_logs_days=7", "--expire_logs_days=7",
"--max_binlog_size=100M" "--max_binlog_size=100M",
] ]
# ===== BACKUP MYSQL =====
backup-mysql:
image: fradelg/mysql-cron-backup
deploy:
replicas: 1
restart_policy:
condition: on-failure
placement:
constraints:
- node.role == manager
environment:
MYSQL_HOST: mysql
MYSQL_USER: root
MYSQL_PASS: ${DB_PASSWORD}
CRON_TIME: "55 2 * * *" # Roda todo dia exatamente às 02:55 da manhã
MAX_BACKUPS: 3 # Mantém apenas os 3 últimos dias
INIT_BACKUP: "1" # Faz um backup imediatamente ao ligar o container
volumes:
- /opt/backups_db/growup-multi:/backup
networks:
- network_public
# ===== REDIS ===== # ===== REDIS =====
redis: redis:
image: redis:latest image: redis:latest
command: command: ["redis-server", "--appendonly", "yes", "--port", "6379"]
[
"redis-server",
"--appendonly",
"yes",
"--port",
"6379"
]
volumes: volumes:
- redis_data:/data - redis_data:/data
networks: networks:

View File