Updated to support split carp roles

This commit is contained in:
2026-04-29 10:03:05 -07:00
parent 7fcecba4f5
commit c0d887eed2

View File

@@ -13,15 +13,15 @@
ansible.builtin.import_tasks: update_check.yml ansible.builtin.import_tasks: update_check.yml
tags: [always, check] tags: [always, check]
# --- CARP/HA PRE-UPGRADE LOGIC (before upgrade) --- # CARP pre-upgrade (demotion)
- name: Include CARP/HA pre-upgrade logic - name: Include CARP pre-upgrade logic
ansible.builtin.import_tasks: carp.yml ansible.builtin.import_tasks: carp_pre.yml
tags: [always, check, carp] tags: [always, check, carp]
when: when:
- ha_peer is defined - ha_peer is defined
- ha_peer | length > 0 - ha_peer | length > 0
# --- UPGRADE EXECUTION --- # Upgrade execution
- name: Include upgrade execution - name: Include upgrade execution
ansible.builtin.import_tasks: upgrade.yml ansible.builtin.import_tasks: upgrade.yml
tags: [upgrade] tags: [upgrade]
@@ -29,15 +29,16 @@
- perform_upgrade | bool - perform_upgrade | bool
- upgrade_available | bool - upgrade_available | bool
# --- CARP/HA POST-UPGRADE RESTORE (after upgrade) --- # CARP post-upgrade (restore)
- name: Include CARP/HA post-upgrade restore - name: Include CARP post-upgrade restore
ansible.builtin.import_tasks: carp.yml ansible.builtin.import_tasks: carp_post.yml
tags: [upgrade, carp] tags: [upgrade, carp]
when: when:
- ha_peer is defined - ha_peer is defined
- ha_peer | length > 0 - ha_peer | length > 0
- perform_upgrade | bool - perform_upgrade | bool
# Verification
- name: Include post-upgrade verification - name: Include post-upgrade verification
ansible.builtin.import_tasks: verify.yml ansible.builtin.import_tasks: verify.yml
tags: [upgrade, verify] tags: [upgrade, verify]