Skip to content
main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
bashutils/docker-volume-backup/
bashutils/docker-volume-backup/

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 

Backing up Docker container volumes

This script creates a *.tar archive for each volume mounted to a specific Docker container.

In order to quickly back up all volumes of your container:

  • Install jq on your system
  • Run ./backup-volumes-container.sh <container-name>

As a result, a directory will be created at in your current working folder with the name backup-<container name>-<current date>. In that newly created directory there will be one tar archive for each volume mounted to the specified container. The name of the archive will be <volume-name>.tar

Kommet platform

This code is derived from work done on the Kommet platform. Visit https://kommet.io for details.