Move verify backup into separate playbook

This commit is contained in:
Tobias Reisinger 2025-01-09 02:45:44 +01:00
parent 09bc8b3d12
commit f48e702339
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE
2 changed files with 15 additions and 11 deletions

View file

@ -35,14 +35,3 @@
ansible.builtin.import_tasks: recovery.yml
- name: Import tasks specific to systemd
ansible.builtin.import_tasks: systemd.yml
- name: Verify service
ansible.builtin.command:
cmd: autorestic -v check
chdir: "{{ service_path }}"
changed_when: false
become: true
register: cmd_result_verify
until: "cmd_result_verify is not failed"
retries: 10
delay: 10

View file

@ -0,0 +1,15 @@
---
- name: Unlock backups
hosts: serguzim_net
become: true
tasks:
- name: Verify backup
ansible.builtin.command:
cmd: autorestic -v check
chdir: "{{ (services_path, 'backup') | path_join }}"
changed_when: false
become: true
register: cmd_result_verify
until: "cmd_result_verify is not failed"
retries: 10
delay: 10