Failures will result in cleanup. Pt 2.

This commit is contained in:
Chris Hammer 2025-02-05 15:35:17 -05:00
parent d0888f3737
commit f8780d1272

View File

@ -58,6 +58,12 @@
vars: vars:
bigboot_partition_size: "{{ bigboot_size_target }}" bigboot_partition_size: "{{ bigboot_size_target }}"
- name: Failure on request
ansible.builtin.fail:
msg: "Ansible job has been failed upon request."
when:
- bigboot_fail_request | default(false) | bool
rescue: rescue:
- name: Cleanup from any previous executions - name: Cleanup from any previous executions
ansible.builtin.import_tasks: tasks/cleanup.yml ansible.builtin.import_tasks: tasks/cleanup.yml