Trying to stop carp on non ha_peer systems
This commit is contained in:
@@ -19,6 +19,14 @@
|
|||||||
tags: [always, backup]
|
tags: [always, backup]
|
||||||
when: perform_upgrade | bool
|
when: perform_upgrade | bool
|
||||||
|
|
||||||
|
- name: DEBUG - Check CARP conditions
|
||||||
|
ansible.builtin.debug:
|
||||||
|
msg:
|
||||||
|
- "ha_peer is defined: {{ ha_peer is defined }}"
|
||||||
|
- "ha_peer value: {{ ha_peer | default('UNDEFINED') }}"
|
||||||
|
- "ha_peer length: {{ ha_peer | length if ha_peer is defined else 'N/A' }}"
|
||||||
|
when: always
|
||||||
|
|
||||||
# CARP pre-upgrade (demotion)
|
# CARP pre-upgrade (demotion)
|
||||||
- name: Include CARP pre-upgrade logic
|
- name: Include CARP pre-upgrade logic
|
||||||
ansible.builtin.import_tasks: carp_pre.yml
|
ansible.builtin.import_tasks: carp_pre.yml
|
||||||
@@ -26,6 +34,7 @@
|
|||||||
when:
|
when:
|
||||||
- ha_peer is defined
|
- ha_peer is defined
|
||||||
- ha_peer | length > 0
|
- ha_peer | length > 0
|
||||||
|
- upgrade_available | bool # Also only if upgrade is available
|
||||||
|
|
||||||
# Upgrade execution
|
# Upgrade execution
|
||||||
- name: Include upgrade execution
|
- name: Include upgrade execution
|
||||||
@@ -43,6 +52,7 @@
|
|||||||
- ha_peer is defined
|
- ha_peer is defined
|
||||||
- ha_peer | length > 0
|
- ha_peer | length > 0
|
||||||
- perform_upgrade | bool
|
- perform_upgrade | bool
|
||||||
|
- upgrade_available | bool # Also only if upgrade is available
|
||||||
|
|
||||||
# Verification
|
# Verification
|
||||||
- name: Include post-upgrade verification
|
- name: Include post-upgrade verification
|
||||||
|
|||||||
Reference in New Issue
Block a user