15 lines
314 B
Django/Jinja
Executable file
15 lines
314 B
Django/Jinja
Executable file
#!/bin/bash
|
|
set -euo pipefail
|
|
|
|
{% if backup_backend == 'restic' %}
|
|
# restic backend
|
|
source /etc/backup-client/restic.env
|
|
|
|
restic check --read-data \
|
|
--cleanup-cache{% if not backup_restic_cache %} --no-cache{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% if not backup_backend %}
|
|
echo "Noop, backup is handled external"
|
|
{% endif %}
|