Infrastruktur – News

Smart backup of Docker volumes

28 April 2016

For years, we have used Duplicity to perform most of our backups in production. When we started putting Docker in production, we had to ask ourselves how we were going to backup the data. We looked at several solutions and could not find a simple, dynamic and straightforward one.

This is the reason why we created Conplicity, a simple Go tool using Duplicity to automatically backup named volumes of a local Docker engine.

Conplicity lists all local Docker volumes and performs a backup if the volume is named. It can also detect if the volume is used by a PostgreSQL, MySQL or OpenLDAP database, and launch a command in the container to dump the data before performing the backup. The backup parameters can be tuned by attaching labels to the volume (using e.g. the new Docker Compose v2 format).

Since it uses Duplicity, it allows to backup to both S3 and Swift, currently.

Docker images are available, and we are working on a Rancher Catalog template to automate its deployment.