backup stuff
This commit is contained in:
parent
01b83a80ec
commit
27e036eccd
16 changed files with 513 additions and 0 deletions
21
ansible/services/headscale/setup_backup_headscale.yml
Normal file
21
ansible/services/headscale/setup_backup_headscale.yml
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
---
|
||||
- name: Configure the Headscale backup on the vpn_control host
|
||||
hosts: vpn_control
|
||||
become: yes
|
||||
vars_files:
|
||||
- ../../group_vars/all/main.yml
|
||||
- ./headscale_vars.yml
|
||||
|
||||
tasks:
|
||||
- name: Ensure Headscale dumps itself, encrypted, on a timer
|
||||
ansible.builtin.include_role:
|
||||
name: backup_source
|
||||
vars:
|
||||
backup_source_name: headscale
|
||||
backup_source_description: "Headscale"
|
||||
# -C / with relative paths: avoids tar's "removing leading /" and makes
|
||||
# the restore target explicit.
|
||||
backup_source_dump_command: "tar -czf - -C / var/lib/headscale etc/headscale"
|
||||
backup_source_stop_service: headscale
|
||||
backup_source_retention_days: 7
|
||||
backup_source_on_calendar: "*-*-* 02:00:00"
|
||||
Loading…
Add table
Add a link
Reference in a new issue