summaryrefslogtreecommitdiffstats
path: root/docker/services/pacemaker/cinder-backup.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'docker/services/pacemaker/cinder-backup.yaml')
-rw-r--r--docker/services/pacemaker/cinder-backup.yaml25
1 files changed, 23 insertions, 2 deletions
diff --git a/docker/services/pacemaker/cinder-backup.yaml b/docker/services/pacemaker/cinder-backup.yaml
index ee8ee124..26ae9bca 100644
--- a/docker/services/pacemaker/cinder-backup.yaml
+++ b/docker/services/pacemaker/cinder-backup.yaml
@@ -139,6 +139,27 @@ outputs:
- /var/lib/cinder
- /var/log/containers/cinder
upgrade_tasks:
- - name: Stop and disable cinder_backup service
+ - name: get bootstrap nodeid
+ tags: common
+ command: hiera -c /etc/puppet/hiera.yaml bootstrap_nodeid
+ register: bootstrap_node
+ - name: set is_bootstrap_node fact
+ tags: common
+ set_fact: is_bootstrap_node={{bootstrap_node.stdout|lower == ansible_hostname|lower}}
+ - name: Disable the openstack-cinder-backup cluster resource
tags: step2
- service: name=openstack-cinder-backup state=stopped enabled=no
+ pacemaker_resource:
+ resource: openstack-cinder-backup
+ state: disable
+ wait_for_resource: true
+ when: is_bootstrap_node
+ - name: Delete the stopped openstack-cinder-backup cluster resource.
+ tags: step2
+ pacemaker_resource:
+ resource: openstack-cinder-backup
+ state: delete
+ wait_for_resource: true
+ when: is_bootstrap_node
+ - name: Disable cinder_backup service
+ tags: step2
+ service: name=openstack-cinder-backup enabled=no