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: I6749670146cc64cb39b67efb26a9226208828ae7
This commit is contained in:
parent
3ffa50e1c6
commit
fb2802d2e4
@ -29,7 +29,7 @@
|
|||||||
daemon_reload: "{{ (ansible_service_mgr == 'systemd') | ternary('yes', omit) }}"
|
daemon_reload: "{{ (ansible_service_mgr == 'systemd') | ternary('yes', omit) }}"
|
||||||
with_items: "{{ filtered_glance_services }}"
|
with_items: "{{ filtered_glance_services }}"
|
||||||
register: _stop
|
register: _stop
|
||||||
until: _stop | success
|
until: _stop is success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
listen: "Restart glance services"
|
listen: "Restart glance services"
|
||||||
@ -110,7 +110,7 @@
|
|||||||
daemon_reload: "{{ (ansible_service_mgr == 'systemd') | ternary('yes', omit) }}"
|
daemon_reload: "{{ (ansible_service_mgr == 'systemd') | ternary('yes', omit) }}"
|
||||||
with_items: "{{ filtered_glance_services }}"
|
with_items: "{{ filtered_glance_services }}"
|
||||||
register: _start
|
register: _start
|
||||||
until: _start | success
|
until: _start is success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
listen: "Restart glance services"
|
listen: "Restart glance services"
|
||||||
|
@ -84,7 +84,7 @@
|
|||||||
update_cache: "{{ (ansible_pkg_mgr in ['apt', 'zypper']) | ternary('yes', omit) }}"
|
update_cache: "{{ (ansible_pkg_mgr in ['apt', 'zypper']) | ternary('yes', omit) }}"
|
||||||
cache_valid_time: "{{ (ansible_pkg_mgr == 'apt') | ternary(cache_timeout, omit) }}"
|
cache_valid_time: "{{ (ansible_pkg_mgr == 'apt') | ternary(cache_timeout, omit) }}"
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages | success
|
until: install_packages is success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
|
|
||||||
|
@ -41,21 +41,21 @@
|
|||||||
file:
|
file:
|
||||||
path: "{{ glance_bin | dirname }}"
|
path: "{{ glance_bin | dirname }}"
|
||||||
state: absent
|
state: absent
|
||||||
when: glance_get_venv | changed
|
when: glance_get_venv is changed
|
||||||
|
|
||||||
- name: Create glance venv dir
|
- name: Create glance venv dir
|
||||||
file:
|
file:
|
||||||
path: "{{ glance_bin | dirname }}"
|
path: "{{ glance_bin | dirname }}"
|
||||||
state: directory
|
state: directory
|
||||||
register: glance_venv_dir
|
register: glance_venv_dir
|
||||||
when: glance_get_venv | changed
|
when: glance_get_venv is changed
|
||||||
|
|
||||||
- name: Unarchive pre-built venv
|
- name: Unarchive pre-built venv
|
||||||
unarchive:
|
unarchive:
|
||||||
src: "/var/cache/{{ glance_venv_download_url | basename }}"
|
src: "/var/cache/{{ glance_venv_download_url | basename }}"
|
||||||
dest: "{{ glance_bin | dirname }}"
|
dest: "{{ glance_bin | dirname }}"
|
||||||
copy: "no"
|
copy: "no"
|
||||||
when: glance_get_venv | changed
|
when: glance_get_venv is changed
|
||||||
notify:
|
notify:
|
||||||
- Manage LB
|
- Manage LB
|
||||||
- Restart glance services
|
- Restart glance services
|
||||||
@ -71,7 +71,7 @@
|
|||||||
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
||||||
{{ pip_install_options | default('') }}
|
{{ pip_install_options | default('') }}
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages|success
|
until: install_packages is success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
when: glance_get_venv | failed or glance_get_venv | skipped
|
when: glance_get_venv | failed or glance_get_venv | skipped
|
||||||
@ -85,7 +85,7 @@
|
|||||||
state: "absent"
|
state: "absent"
|
||||||
when:
|
when:
|
||||||
- ansible_pkg_mgr in ['yum', 'dnf', 'zypper']
|
- ansible_pkg_mgr in ['yum', 'dnf', 'zypper']
|
||||||
- glance_get_venv | changed
|
- glance_get_venv is changed
|
||||||
|
|
||||||
# NOTE(odyssey4me):
|
# NOTE(odyssey4me):
|
||||||
# We reinitialize the venv to ensure that the right
|
# We reinitialize the venv to ensure that the right
|
||||||
@ -103,7 +103,7 @@
|
|||||||
--no-pip \
|
--no-pip \
|
||||||
--no-setuptools \
|
--no-setuptools \
|
||||||
--no-wheel
|
--no-wheel
|
||||||
when: glance_get_venv | changed
|
when: glance_get_venv is changed
|
||||||
tags:
|
tags:
|
||||||
- skip_ansible_lint
|
- skip_ansible_lint
|
||||||
|
|
||||||
|
@ -38,7 +38,7 @@
|
|||||||
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
||||||
{{ pip_install_options | default('') }}
|
{{ pip_install_options | default('') }}
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages | success
|
until: install_packages is success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
|
|
||||||
|
@ -71,7 +71,7 @@
|
|||||||
enabled: "yes"
|
enabled: "yes"
|
||||||
state: "restarted"
|
state: "restarted"
|
||||||
when:
|
when:
|
||||||
- nfs_exportfs | changed
|
- nfs_exportfs is changed
|
||||||
|
|
||||||
- name: Export NFS
|
- name: Export NFS
|
||||||
command: exportfs -rav
|
command: exportfs -rav
|
||||||
|
Loading…
x
Reference in New Issue
Block a user