TripleO Ansible project repository. Contains playbooks for use with TripleO OpenStack deployments.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.7 KiB

# Copyright 2019 Red Hat, Inc.
# All Rights Reserved.
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
# Call to podman to list running containers then commit all state to
# disk. Once services state has been flushed dump the database then allow
# the backup to start.
- name: Enable pacemaker
command: pcs cluster start --all
when: enabled_galera
run_once: true
- bar_create_recover_image
- name: unPause database container
command: "{{ tripleo_container_cli }} unpause {{ tripleo_backup_and_restore_mysql_container }}"
- tripleo_container_cli is defined
- not enabled_galera
- tripleo_backup_and_restore_mysql_container is defined
- bar_create_recover_image
- name: Gather Container Service Name
shell: |
set -o pipefail
/usr/bin/{{ tripleo_container_cli }} ps -a --filter='status=paused' --format '{{ '{{' }}.Names {{ '}}' }} '
register: container_services
changed_when: container_services.stdout is defined
- bar_create_recover_image
- name: unPause containers
command: "{{ tripleo_container_cli }} unpause {{ item }}"
with_items: "{{ container_services.stdout_lines }}"
when: tripleo_container_cli is defined
- bar_create_recover_image