Backup databases mysql and postgres from docker’s
Backup databases mysql and postgres in containers. Add to crontabs like this 00 00 * * * bash /docker-compose/scripts/backup_db.sh “ARG_BACKUP_ROOT_DIR=/docker-compose/bup” “ARG_DB_STACK_POSTGRES=docker” “ARG_DB_STACK_MYSQL=docker” “ARG_DAYS_TO_STORE_BACKUP=30” “ARG_DOW_FOR_VACUUM=6” #!/bin/bash #bash /docker-compose/scripts/backup_db.sh “ARG_BACKUP_ROOT_DIR=/docker-compose/bup” “ARG_DB_STACK_POSTGRES=docker” “ARG_DB_STACK_MYSQL=docker” “ARG_DAYS_TO_STORE_BACKUP=30” “ARG_DOW_FOR_VACUUM=6″ DATE_BACKUP=$(date +”%Y-%m-%d”) DOW=$(date +%u) ##Вход переменная backup dir ARG_BACKUP_ROOT_DIR=”$1″ BACKUP_ROOT_DIR=$(echo “${ARG_BACKUP_ROOT_DIR}” | cut -d\= -f2) ##Вход переменная DB_STACK_POSTGRES – native or docker ARG_DB_STACK_POSTGRES=”$2″ […]
Читать дальше… from Backup databases mysql and postgres from docker’s