--- - name: Configure the Headscale backup on the vpn_control host hosts: vpn_control become: yes vars_files: - ./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" # Reported to Gatus as backup-dump_headscale. The token is this HOST's token, # shared with its other checks - see infra/400_host_monitoring.yml. backup_source_push_url: "https://{{ subdomains.gatus }}.{{ root_domain }}/api/v1/endpoints/backup-dump_headscale/external" backup_source_push_token: "{{ gatus_push_tokens[inventory_hostname] }}"