Fix warning on {failed|changed}_when statements
Ansible 2.3.0 does not like delimiters in when statement. Related link: https://github.com/ansible/ansible/issues/22397 Closes-Bug: #1714349 Change-Id: I973cc6537c4c1374546b5cddb4ce713a553b92f4
This commit is contained in:
parent
9a520e0906
commit
191e268575
@ -18,7 +18,7 @@
|
|||||||
--os-project-name={{ openstack_auth.project_name }} \
|
--os-project-name={{ openstack_auth.project_name }} \
|
||||||
secret get -f value -p {{ barbican_store_secret.stdout }}
|
secret get -f value -p {{ barbican_store_secret.stdout }}
|
||||||
register: barbican_get_secret
|
register: barbican_get_secret
|
||||||
failed_when: "{{ barbican_get_secret.stdout != 'kolla' }}"
|
failed_when: barbican_get_secret.stdout != 'kolla'
|
||||||
run_once: True
|
run_once: True
|
||||||
when: kolla_enable_sanity_barbican | bool
|
when: kolla_enable_sanity_barbican | bool
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
-m find_disks
|
-m find_disks
|
||||||
-a "partition_name='KOLLA_CEPH_OSD_BOOTSTRAP' match_mode='prefix' use_udev={{ kolla_ceph_use_udev }}"
|
-a "partition_name='KOLLA_CEPH_OSD_BOOTSTRAP' match_mode='prefix' use_udev={{ kolla_ceph_use_udev }}"
|
||||||
register: osd_lookup
|
register: osd_lookup
|
||||||
changed_when: "{{ osd_lookup.stdout.find('localhost | SUCCESS => ') != -1 and (osd_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed }}"
|
changed_when: osd_lookup.stdout.find('localhost | SUCCESS => ') != -1 and (osd_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed
|
||||||
failed_when: osd_lookup.stdout.split()[2] != 'SUCCESS'
|
failed_when: osd_lookup.stdout.split()[2] != 'SUCCESS'
|
||||||
|
|
||||||
- name: Parsing disk info for Ceph OSDs
|
- name: Parsing disk info for Ceph OSDs
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
-m find_disks
|
-m find_disks
|
||||||
-a "partition_name='KOLLA_CEPH_DATA' match_mode='prefix' use_udev={{ kolla_ceph_use_udev }}"
|
-a "partition_name='KOLLA_CEPH_DATA' match_mode='prefix' use_udev={{ kolla_ceph_use_udev }}"
|
||||||
register: osd_lookup
|
register: osd_lookup
|
||||||
changed_when: "{{ osd_lookup.stdout.find('localhost | SUCCESS => ') != -1 and (osd_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed }}"
|
changed_when: osd_lookup.stdout.find('localhost | SUCCESS => ') != -1 and (osd_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed
|
||||||
failed_when: osd_lookup.stdout.split()[2] != 'SUCCESS'
|
failed_when: osd_lookup.stdout.split()[2] != 'SUCCESS'
|
||||||
when: inventory_hostname in groups['ceph-osd']
|
when: inventory_hostname in groups['ceph-osd']
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
auth={{ '{{ openstack_swift_auth }}' }}"
|
auth={{ '{{ openstack_swift_auth }}' }}"
|
||||||
-e "{'openstack_swift_auth':{{ openstack_swift_auth }}}"
|
-e "{'openstack_swift_auth':{{ openstack_swift_auth }}}"
|
||||||
register: swift_sanity
|
register: swift_sanity
|
||||||
changed_when: "{{ swift_sanity.stdout.find('localhost | SUCCESS => ') != -1 and (swift_sanity.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed }}"
|
changed_when: swift_sanity.stdout.find('localhost | SUCCESS => ') != -1 and (swift_sanity.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed
|
||||||
until: swift_sanity.stdout.split()[2] == 'SUCCESS'
|
until: swift_sanity.stdout.split()[2] == 'SUCCESS'
|
||||||
retries: 10
|
retries: 10
|
||||||
delay: 5
|
delay: 5
|
||||||
|
@ -5,8 +5,8 @@
|
|||||||
-a "name={{ swift_devices_name }}
|
-a "name={{ swift_devices_name }}
|
||||||
match_mode={{ swift_devices_match_mode }}"
|
match_mode={{ swift_devices_match_mode }}"
|
||||||
register: swift_disk_lookup
|
register: swift_disk_lookup
|
||||||
changed_when: "{{ swift_disk_lookup.stdout.find('localhost | SUCCESS => ') != -1 and
|
changed_when: swift_disk_lookup.stdout.find('localhost | SUCCESS => ') != -1 and
|
||||||
(swift_disk_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed }}"
|
(swift_disk_lookup.stdout.split('localhost | SUCCESS => ')[1]|from_json).changed
|
||||||
failed_when: swift_disk_lookup.stdout.split()[2] != 'SUCCESS'
|
failed_when: swift_disk_lookup.stdout.split()[2] != 'SUCCESS'
|
||||||
when: inventory_hostname in groups['swift-account-server'] or
|
when: inventory_hostname in groups['swift-account-server'] or
|
||||||
inventory_hostname in groups['swift-container-server'] or
|
inventory_hostname in groups['swift-container-server'] or
|
||||||
|
Loading…
Reference in New Issue
Block a user