Journal 2022-06-28
Docker
Backup a volume
- Official documentation: docs docker
- Create a container with the volumes for the backup and restore:
docker run -v /dbdata --name dbstore ubuntu /bin/bash
- Create the backup in the current directory
docker run --rm --volumes-from dbstore -v $(pwd):/backup ubuntu tar cvf /backup/backup.tar /dbdata