Do not stop the pacemaker cluster if this is a remote node
Stopping the pacemaker cluster should only be attempted on a full cluster node. Let's check if the host is running pacemaker_remote so to filter it out. Change-Id: Ia95b1c1eaed57f34d857b9dc5a6b803815bdca3b
This commit is contained in:
parent
731b595b7e
commit
68b665a8d3
@ -207,12 +207,14 @@ outputs:
|
||||
stat:
|
||||
path: /usr/sbin/pcs
|
||||
register: pcs_stat
|
||||
- name: Gather running services
|
||||
ansible.builtin.service_facts:
|
||||
- name: Stop pacemaker cluster before stopping all docker containers
|
||||
# NOTE: We are intentionally not using the community version of
|
||||
# pacemaker_cluster here due to variances between the two:
|
||||
# https://bugs.launchpad.net/tripleo/+bug/1938967
|
||||
pacemaker_cluster: state=offline
|
||||
when: pcs_stat.stat.exists
|
||||
when: pcs_stat.stat.exists and ( ansible_facts.services['pacemaker_remote.service'].state != "running" )
|
||||
|
||||
- name: system_upgrade_prepare step 5
|
||||
tags:
|
||||
|
Loading…
x
Reference in New Issue
Block a user