From dab13a23889aee8571169da9a4e5742aea374c38 Mon Sep 17 00:00:00 2001 From: phil Date: Sun, 9 Apr 2023 10:41:54 +0200 Subject: [PATCH] Read borgbase repository dynamically No need to configure it in host_vars --- templates/config.yaml.j2 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/templates/config.yaml.j2 b/templates/config.yaml.j2 index 6b659a8..cfaf2e1 100644 --- a/templates/config.yaml.j2 +++ b/templates/config.yaml.j2 @@ -17,9 +17,13 @@ location: # Stay in same file system (do not cross mount points). one_file_system: {{ borg_one_file_system }} repositories: +{% if borgbase is define and borgbase %} + - ssh://{{ borgbase_repo.repo_id }}@{{ borgbackup_ssh_host }}/./repo" +{% else %} {% for repo in borg_repository %} - {{ repo.path }} {% endfor %} +{% endif %} # Store atime into archive. atime: {{ borgmatic_store_atime }}