diff --git a/tasks/00_assert.yml b/tasks/00_assert.yml new file mode 100644 index 0000000..4cbabd3 --- /dev/null +++ b/tasks/00_assert.yml @@ -0,0 +1,9 @@ +--- +- name: Ensure legacy hooks aren't used + ansible.builtin.assert: + that: + - borgmatic_failure_command is undefined + - borgmatic_before_backup_command is undefined + - borgmatic_after_backup_command is undefined + msg: Please use the new borgmatic_hooks variable instead of individual before/after/failure hooks. +... diff --git a/tasks/01_install.yml b/tasks/01_install.yml index e4478d9..83896fc 100644 --- a/tasks/01_install.yml +++ b/tasks/01_install.yml @@ -1,14 +1,6 @@ --- - name: Install borgbackup block: - - name: Ensure legacy hooks aren't used - ansible.builtin.assert: - that: - - borgmatic_failure_command is undefined - - borgmatic_before_backup_command is undefined - - borgmatic_after_backup_command is undefined - msg: Please use the new borgmatic_hooks variable instead of individual before/after/failure hooks. - - name: Include OS-specific variables include_vars: "{{ item }}" with_first_found: