Sign inSign up

hcdesigns/mysql-backup

By hcdesigns

•Updated over 5 years ago

Backup multiple MySQL/MariaDB databases with Docker

Image
0

1.9K

hcdesigns/mysql-backup repository overview

⁠MySQL Backup container

This container uses mysql_dump to backup all databases on a mysql or mariadb database server.

⁠Variables

VariableValueDefault
BACKUP_DIRBackup destination/backup
MYSQL_UNAMEMysql username
MYSQL_PWORDMysql password
MYSQL_HOSTMysql hostlocalhost
MYSQL_PORTMysql port3306
IGNORE_DBDon't backup databases with these names with regex(^mysql|_schema$|_test|sys$)
KEEP_BACKUPS_FORDays to keep backups7

⁠Example

docker run -e MYSQL_UNAME=backup \
           -e MYSQL_PWORD=backup \
           hcdesigns/docker-mysql-backup

⁠Credits

For original backup script: https://gist.github.com/tleish/1c6e788c84f59200446b⁠

Tag summary

Content type

Image

Digest

Size

13.9 MB

Last updated

over 5 years ago

docker pull hcdesigns/mysql-backup