]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
validate: force ansible version
authorSébastien Han <seb@redhat.com>
Thu, 12 Jul 2018 09:31:00 +0000 (11:31 +0200)
committermergify[bot] <mergify[bot]@users.noreply.github.com>
Fri, 13 Jul 2018 07:52:56 +0000 (07:52 +0000)
We currently only support Ansible 2.4.X so let's fail if the version is
different.

Signed-off-by: Sébastien Han <seb@redhat.com>
roles/ceph-validate/tasks/check_system.yml

index dc39509d84f0d0e481fad8319ded99a760671ea9..2f8f8054e5e521d26e9f65d32ad0c4049ddb76db 100644 (file)
     - ansible_distribution == 'openSUSE Leap'
     - ansible_distribution_version | version_compare('42.3', '<')
 
-- name: fail on unsupported ansible version
+- name: fail on unsupported ansible version (1.X)
   fail:
-    msg: "Ansible version must be >= 2.3.x, please update!"
+    msg: "Ansible version must be >= 2.4.x, please update!"
   when:
     - ansible_version.major|int < 2
 
 - name: fail on unsupported ansible version
   fail:
-    msg: "Ansible version must be >= 2.3.x, please update!"
+    msg: "Ansible version must be between 2.4.x and 2.5.x!"
   when:
     - ansible_version.major|int == 2
-    - ansible_version.minor|int < 3
+    - (ansible_version.minor|int < 4 or ansible_version.minor|int > 5)
 
 - name: fail if systemd is not present
   fail: