From ca8f41f341169a18b47ed626db26c2b2c1179945 Mon Sep 17 00:00:00 2001 From: Kyle Manna Date: Sun, 6 Jul 2014 00:11:27 -0700 Subject: [PATCH] backup: Add restore step * Add restore step * Use lzma compression since we're in the 2010's --- docs/backup.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/backup.md b/docs/backup.md index 1903e0e..a16ee26 100644 --- a/docs/backup.md +++ b/docs/backup.md @@ -9,6 +9,10 @@ I'd recommend encrypting the archive with something strong (e.g. gpg or openssl TL;DR Protect the resulting archive file, by ensure there is very limited access to it. -## Simple +## Backup to Archive - docker run --volumes-from openvpn-data --rm kylemanna/openvpn tar czf - -C /etc openvpn > openvpn-backup.tar.gz + docker run --volumes-from openvpn-data --rm busybox tar -cvf - -C /etc openvpn | xz > openvpn-backup.tar.xz + +## Retore to New Image + + xzcat openvpn-backup.tar.xz | docker run --name openvpn-data -v /etc/openvpn -i busybox tar -xvf - -C /etc