Avoid Ansible Deprecation Warning

Using Ansible provided Jinja tests as filters is deprecated

Change-Id: I03b6b9760d102608a1d814e6073a459226482dde
Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
This commit is contained in:
Gael Chamoulaud 2018-10-31 12:10:06 +01:00
parent 1ff8160f17
commit 78e40b5702
3 changed files with 4 additions and 4 deletions

View File

@ -16,5 +16,5 @@
changed_when: False
- name: Detect whether the drive uses Advanced Format
advanced_format: drive={{ item }}
when: item|match("^sd.$")
when: item is match("^sd.$")
with_items: "{{ drive_list.stdout_lines }}"

View File

@ -19,4 +19,4 @@
warn:
msg: If planning to use Ceph, it is necessary to install the ceph-ansible on the undercloud
when:
- ceph_ansible_installed|failed
- ceph_ansible_installed is failed

View File

@ -21,10 +21,10 @@
shell: ceph health | awk '{print $1}'
register: ceph_health
when:
- ceph_mon_enabled|succeeded
- ceph_mon_enabled is succeeded
- name: Check ceph health
warn:
msg: Ceph is in {{ ceph_health.stdout }} state.
when:
- ceph_mon_enabled|succeeded
- ceph_mon_enabled is succeeded
- ceph_health.stdout == 'HEALTH_WARN'