From 4f857f3d7ed906f7944278b1dd4f111e91b3ef78 Mon Sep 17 00:00:00 2001 From: Karl DeBisschop Date: Mon, 29 Jan 2024 13:28:00 -0500 Subject: [PATCH] if using files_from, BACKUP_SOURCES need to exist and be empty --- templates/restic_script_Linux.j2 | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/templates/restic_script_Linux.j2 b/templates/restic_script_Linux.j2 index 2995e84..1b5d11e 100644 --- a/templates/restic_script_Linux.j2 +++ b/templates/restic_script_Linux.j2 @@ -78,12 +78,7 @@ export B2_ACCOUNT_ID={{ restic_repos[item.repo].b2_account_id }} {% if restic_repos[item.repo].b2_account_key is defined %} export B2_ACCOUNT_KEY={{ restic_repos[item.repo].b2_account_key }} {% endif %} -{% if item.src is defined and item.src is string %} -BACKUP_SOURCE="{{ item.src }}" -{% endif %} -{% if item.src is defined and item.src.__class__.__name__ =='list' %} -BACKUP_SOURCE="{{ item.src| join(' ') }}" -{% endif %} +BACKUP_SOURCE="{% if item.src is defined %}{% if item.src is string %}{{ item.src }}{% elif item.src.__class__.__name__ =='list' %}{{ item.src| join(' ') }}{% endif %}{% endif %}" {% if item.lvm is defined %} # Set up functions for LVM.