Fix usage of "|" for tests
With the more recent versions of ansible, we should now use "is" instead of the "|" sign for the tests. This should fix it. Change-Id: Iee01cc384368c76cf191244f4988ef735ee3d5d7
This commit is contained in:
parent
4b46ce34a7
commit
402c012b9f
|
@ -16,7 +16,7 @@
|
|||
url: "{{ monasca_service_internalurl }}"
|
||||
status_code: 401
|
||||
register: result
|
||||
until: result|success
|
||||
until: result is success
|
||||
retries: 5
|
||||
delay: 2
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
update_cache: "{{ (ansible_pkg_mgr == 'apt') | ternary('yes', omit) }}"
|
||||
cache_valid_time: "{{ (ansible_pkg_mgr == 'apt') | ternary(cache_timeout, omit) }}"
|
||||
register: install_packages
|
||||
until: install_packages | success
|
||||
until: install_packages is success
|
||||
retries: 5
|
||||
delay: 2
|
||||
|
||||
|
@ -56,21 +56,21 @@
|
|||
file:
|
||||
path: "{{ monasca_bin | dirname }}"
|
||||
state: absent
|
||||
when: monasca_get_venv | changed
|
||||
when: monasca_get_venv is changed
|
||||
|
||||
- name: Create monasca venv dir
|
||||
file:
|
||||
path: "{{ monasca_bin | dirname }}"
|
||||
state: directory
|
||||
register: monasca_venv_dir
|
||||
when: monasca_get_venv | changed
|
||||
when: monasca_get_venv is changed
|
||||
|
||||
- name: Unarchive pre-built venv
|
||||
unarchive:
|
||||
src: "/var/cache/{{ monasca_venv_download_url | basename }}"
|
||||
dest: "{{ monasca_bin | dirname }}"
|
||||
copy: "no"
|
||||
when: monasca_get_venv | changed
|
||||
when: monasca_get_venv is changed
|
||||
notify:
|
||||
- Restart monasca services
|
||||
|
||||
|
@ -85,7 +85,7 @@
|
|||
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
||||
{{ pip_install_options | default('') }}
|
||||
register: install_packages
|
||||
until: install_packages|success
|
||||
until: install_packages is success
|
||||
retries: 5
|
||||
delay: 2
|
||||
when: monasca_get_venv | failed or monasca_get_venv | skipped
|
||||
|
@ -98,7 +98,7 @@
|
|||
state: "absent"
|
||||
when:
|
||||
- ansible_pkg_mgr == 'yum'
|
||||
- monasca_get_venv | changed
|
||||
- monasca_get_venv is changed
|
||||
|
||||
# NOTE(odyssey4me):
|
||||
# We reinitialize the venv to ensure that the right
|
||||
|
@ -116,6 +116,6 @@
|
|||
--no-pip \
|
||||
--no-setuptools \
|
||||
--no-wheel
|
||||
when: monasca_get_venv | changed
|
||||
when: monasca_get_venv is changed
|
||||
tags:
|
||||
- skip_ansible_lint
|
||||
|
|
|
@ -30,4 +30,4 @@
|
|||
command: "/opt/kafka/bin/kafka-topics.sh --create --zookeeper {{ zookeeper_hosts }} --replication-factor {{ item.value.replicas }} --partitions {{ item.value.partitions }} --topic {{ item.key }}"
|
||||
with_dict: "{{ kafka_topics }}"
|
||||
when:
|
||||
- check_result | failed
|
||||
- check_result is failed
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
force: yes
|
||||
accept_hostkey: yes
|
||||
register: git_clone
|
||||
until: git_clone|success
|
||||
until: git_clone is success
|
||||
retries: 5
|
||||
delay: 2
|
||||
with_items:
|
||||
|
|
Loading…
Reference in New Issue