diff options
author | clarkzjw <[email protected]> | 2023-02-08 00:40:09 -0800 |
---|---|---|
committer | clarkzjw <[email protected]> | 2023-02-08 00:40:09 -0800 |
commit | 1204730924436ef9e1c7c49c9557837f9a5ed0e8 (patch) | |
tree | 129d79dfd11245751cee6d4082ff5d2f6e941610 /ansible/roles/backup/templates | |
parent | 9635ac4dedf69de5bff65785bcc16bef80b52d75 (diff) | |
download | mail-master.tar.gz |
Diffstat (limited to 'ansible/roles/backup/templates')
-rw-r--r-- | ansible/roles/backup/templates/borgmatic.yml.j2 | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/ansible/roles/backup/templates/borgmatic.yml.j2 b/ansible/roles/backup/templates/borgmatic.yml.j2 new file mode 100644 index 0000000..864c8a6 --- /dev/null +++ b/ansible/roles/backup/templates/borgmatic.yml.j2 | |||
@@ -0,0 +1,36 @@ | |||
1 | location: | ||
2 | # List of source directories to backup. Globs are expanded. | ||
3 | source_directories: | ||
4 | {% for dir in backup.dirs %} | ||
5 | - {{ dir }} | ||
6 | {% endfor %} | ||
7 | |||
8 | # Paths to local or remote repositories. | ||
9 | repositories: | ||
10 | - {{ backup.host }}:{{ inventory_hostname }} | ||
11 | |||
12 | one_file_system: True | ||
13 | remote_path: borg1 | ||
14 | |||
15 | # Any paths matching these patterns are excluded from backups. | ||
16 | exclude_patterns: | ||
17 | - /home/*/.cache | ||
18 | |||
19 | storage: | ||
20 | encryption_passphrase: {{ backup.phrase }} | ||
21 | compression: lz4 | ||
22 | |||
23 | retention: | ||
24 | # Retention policy for how many backups to keep in each category. | ||
25 | keep_within: 3H | ||
26 | keep_daily: 7 | ||
27 | keep_weekly: 2 | ||
28 | keep_monthly: 3 | ||
29 | |||
30 | consistency: | ||
31 | # List of consistency checks to run: "repository", "archives", or both. | ||
32 | checks: | ||
33 | - repository | ||
34 | - archives | ||
35 | |||
36 | check_last: 1 | ||