allanger-roles/restic-backups
Nikolai Rodionov 5faa530ac9 some fixed 2022-05-07 19:43:12 +02:00
..
defaults init commit 2022-04-08 17:47:04 +02:00
files remove jq from restic script 2022-04-08 18:18:41 +02:00
tasks some fixed 2022-05-07 19:43:12 +02:00
README.md init commit 2022-04-08 17:47:04 +02:00
playbook.yaml init commit 2022-04-08 17:47:04 +02:00

README.md

Restic Role

Role Variables

Variable Required Default Choices Comments
restic_self_update yes false true, false If true, restic will do self-update even if it's not being installed in current run
restic_keep_last yes 7 any integer Restic will not delete the n last snapshots
restic_cron_params yes name: restic_backup
weekday: "*"
minute: "0"
hour: "0"
user: root
valid cron data Params for restic backup cronjob
restic_password yes any string restic password

Example Playbook

Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:

---
- name: Setup restic backups
  vars:
    restic_keep_last: 7
    restic_backup_dirs:
      - /path/to/dir
      - /another/path/to/dir
    restic_cron_params:
      name: restic_backup
      weekday: "*"
      minute: "30"
      hour: "*"
      user: root

  hosts: all
  roles:
    - role: "."