--- # 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # 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 tags: - bar_create_recover_image - name: unPause database container command: "{{ tripleo_container_cli }} unpause {{ tripleo_backup_and_restore_mysql_container }}" when: - tripleo_container_cli is defined - not enabled_galera - tripleo_backup_and_restore_mysql_container is defined tags: - 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 tags: - 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 tags: - bar_create_recover_image