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: Ib42bf56d7151f5af957041e4e61b7cf646819565
This commit is contained in:
parent
3b86334e2f
commit
7fbcb8c98b
@ -18,7 +18,7 @@
|
||||
update_cache: "{{ (ansible_pkg_mgr in ['apt', 'zypper']) | 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
|
||||
with_items: "{{ sahara_distro_packages }}"
|
||||
@ -52,7 +52,7 @@
|
||||
file:
|
||||
path: "{{ sahara_bin | dirname }}"
|
||||
state: absent
|
||||
when: sahara_get_venv | changed
|
||||
when: sahara_get_venv is changed
|
||||
|
||||
- name: Create sahara venv dir
|
||||
file:
|
||||
@ -60,14 +60,14 @@
|
||||
state: directory
|
||||
mode: "0755"
|
||||
register: sahara_venv_dir
|
||||
when: sahara_get_venv | changed
|
||||
when: sahara_get_venv is changed
|
||||
|
||||
- name: Unarchive pre-built venv
|
||||
unarchive:
|
||||
src: "/var/cache/{{ sahara_venv_download_url | basename }}"
|
||||
dest: "{{ sahara_bin | dirname }}"
|
||||
copy: "no"
|
||||
when: sahara_get_venv | changed
|
||||
when: sahara_get_venv is changed
|
||||
notify:
|
||||
- Restart sahara services
|
||||
|
||||
@ -82,7 +82,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: sahara_get_venv | failed or sahara_get_venv | skipped
|
||||
@ -95,7 +95,7 @@
|
||||
state: "absent"
|
||||
when:
|
||||
- ansible_pkg_mgr in ['yum', 'zypper']
|
||||
- sahara_get_venv | changed
|
||||
- sahara_get_venv is changed
|
||||
|
||||
# NOTE(odyssey4me):
|
||||
# We reinitialize the venv to ensure that the right
|
||||
@ -113,7 +113,7 @@
|
||||
--no-pip \
|
||||
--no-setuptools \
|
||||
--no-wheel
|
||||
when: sahara_get_venv | changed
|
||||
when: sahara_get_venv is changed
|
||||
tags:
|
||||
- skip_ansible_lint
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user