replace mysqldump
This commit is contained in:
parent
c6d65a1de1
commit
fc5ccc8c7b
@ -45,8 +45,8 @@ if [ -f 'dump_'"$MYSQL_DB"'.sql' ]; then
|
|||||||
fi
|
fi
|
||||||
DB_BACKUP_FILENAME=$MYSQL_DB'_'$CURRENT_DATETIME'.tar.gz'
|
DB_BACKUP_FILENAME=$MYSQL_DB'_'$CURRENT_DATETIME'.tar.gz'
|
||||||
|
|
||||||
echo 'Exec mysqldump...'
|
echo 'Exec mariadb-dump...'
|
||||||
docker exec -t $DOCKER_SERVICE_NAME mysqldump -u $MYSQL_USER -p$MARIADB_ROOT_PASSWORD $MYSQL_DB > 'dump_'"$MYSQL_DB"'.sql'
|
docker exec -t $DOCKER_SERVICE_NAME mariadb-dump -u $MYSQL_USER -p$MARIADB_ROOT_PASSWORD $MYSQL_DB > 'dump_'"$MYSQL_DB"'.sql'
|
||||||
|
|
||||||
echo 'Pack to tar.gz...'
|
echo 'Pack to tar.gz...'
|
||||||
tar -cf - 'dump_'"$MYSQL_DB"'.sql' | gzip -9 > "$DB_BACKUP_FILENAME"
|
tar -cf - 'dump_'"$MYSQL_DB"'.sql' | gzip -9 > "$DB_BACKUP_FILENAME"
|
||||||
|
Loading…
Reference in New Issue
Block a user