---
- when: validate_ipmi_step|bool
  block:

      - name: Copy validate IPMI template to the undercloud
        template:
            src: validate-overcloud-ipmi-connection.sh.j2
            dest: "{{ working_dir }}/validate-overcloud-ipmi-connection.sh"
            mode: 0755

      - name: wait for  script file to exist
        wait_for: path="{{ working_dir }}/validate-overcloud-ipmi-connection.sh"

      - name: Run the validate IPMI overcloud connection script
        shell: >
          set -o pipefail &&
          {{ working_dir }}/validate-overcloud-ipmi-connection.sh 2>&1
          {{ timestamper_cmd }} | tee {{ working_dir }}/validate-overcloud-ipmi-connection.log
