---
- name: Unsupported OS version on undercloud
  fail:
      msg: "InfraRed supports updates for OpenStack versions 9+"
  when:
      - undercloud_version|openstack_release < 9
      - not undercloud_version|openstack_release in [9, 10, 11]

- name: Checking overcloud_deploy_file
  stat:
      path: "~/overcloud_deploy.sh"
  register: overcloud_deploy_file

- name: Deployment script not found
  fail:
      msg: "Overcloud deployment script not found. Expected path: ~/overcloud_deploy.sh "
  when: not overcloud_deploy_file.stat.exists or not overcloud_deploy_file.stat.executable

---
- name: Unsupported OS version on undercloud
  fail:
      msg: "InfraRed supports updates for OpenStack versions 8+"
  when:
      - undercloud_version|openstack_release not in [8, 9, 10, 11]

- name: Checking overcloud_deploy_file
  stat:
      path: "~/overcloud_deploy.sh"
  register: overcloud_deploy_file

- name: Deployment script not found
  fail:
      msg: "Overcloud deployment script not found. Expected path: ~/overcloud_deploy.sh "
  when: not overcloud_deploy_file.stat.exists or not overcloud_deploy_file.stat.executable

Allow minor updates of OS 8
Allow minor updates of OS 8

Change-Id: I39136c7982d32718e00b4667869d28ac1a7e769f
