Add timestamp to backup

This commit is contained in:
Alex 2020-11-15 20:14:19 +01:00
parent f931dd939c
commit 1bb9c7ce19
2 changed files with 2 additions and 2 deletions

View file

@ -16,5 +16,5 @@ EOF
consul kv export | \
gzip | \
age -r "$(cat /root/.ssh/id_ed25519.pub)" | \
ssh backuphost "cat > $TARGET_SSH_DIR/consul/consul_kv_export.gz.age"
ssh backuphost "cat > $TARGET_SSH_DIR/consul/$(date --iso-8601=minute)_consul_kv_export.gz.age"

View file

@ -15,7 +15,7 @@ job "backup_periodic" {
driver = "docker"
config {
image = "lxpz/backup_consul:11"
image = "lxpz/backup_consul:12"
volumes = [
"secrets/id_ed25519:/root/.ssh/id_ed25519",
"secrets/id_ed25519.pub:/root/.ssh/id_ed25519.pub",