Merge "Fix deprecation warning of ansible-2.5"

This commit is contained in:
Zuul 2018-06-06 06:47:02 +00:00 committed by Gerrit Code Review
commit 647d98f44b
6 changed files with 11 additions and 11 deletions

View File

@ -16,4 +16,4 @@
- name: Define bindep_command fact - name: Define bindep_command fact
set_fact: set_fact:
bindep_command: "{{ bindep_command_type.stdout }}" bindep_command: "{{ bindep_command_type.stdout }}"
when: not bindep_command_type|skipped and bindep_command_type.rc == 0 when: not bindep_command_type is skipped and bindep_command_type.rc == 0

View File

@ -17,17 +17,17 @@
- name: Define bindep_file fact - name: Define bindep_file fact
set_fact: set_fact:
bindep_file: "{{ bindep_other_file_stat.stat.path }}" bindep_file: "{{ bindep_other_file_stat.stat.path }}"
when: not bindep_other_file_stat|skipped and bindep_other_file_stat.stat.exists when: not bindep_other_file_stat is skipped and bindep_other_file_stat.stat.exists
- name: Look for bindep fallback file - name: Look for bindep fallback file
stat: stat:
path: "{{ bindep_fallback }}" path: "{{ bindep_fallback }}"
register: bindep_fallback_file_stat register: bindep_fallback_file_stat
when: bindep_fallback is defined when: bindep_fallback is defined
and not bindep_other_file_stat|skipped and not bindep_other_file_stat is skipped
and not bindep_other_file_stat.stat.exists and not bindep_other_file_stat.stat.exists
- name: Define bindep_file fact - name: Define bindep_file fact
set_fact: set_fact:
bindep_file: "{{ bindep_fallback_file_stat.stat.path }}" bindep_file: "{{ bindep_fallback_file_stat.stat.path }}"
when: not bindep_fallback_file_stat|skipped and bindep_fallback_file_stat.stat.exists when: not bindep_fallback_file_stat is skipped and bindep_fallback_file_stat.stat.exists

View File

@ -19,4 +19,4 @@
- name: Fail if we cannot install all packages - name: Fail if we cannot install all packages
fail: fail:
msg: "bindep failed to install from {{ bindep_file}} - {{ bindep_final_check.stdout }}" msg: "bindep failed to install from {{ bindep_file}} - {{ bindep_final_check.stdout }}"
when: bindep_final_check|failed when: bindep_final_check is failed

View File

@ -18,12 +18,12 @@
msg: "Variable constraints_file is set but file does not exist." msg: "Variable constraints_file is set but file does not exist."
when: when:
- constraints_file is defined - constraints_file is defined
- not stat_results|skipped and not stat_results.stat.exists - not stat_results is skipped and not stat_results.stat.exists
- name: Record file location - name: Record file location
set_fact: set_fact:
upper_constraints: "-c {{ constraints_file }}" upper_constraints: "-c {{ constraints_file }}"
when: not stat_results|skipped and stat_results.stat.exists when: not stat_results is skipped and stat_results.stat.exists
- name: Install babel - name: Install babel
pip: pip:

View File

@ -15,4 +15,4 @@
- name: Record file location - name: Record file location
set_fact: set_fact:
upper_constraints: "-c {{ constraints_file|realpath }}" upper_constraints: "-c {{ constraints_file|realpath }}"
when: not stat_results|skipped and stat_results.stat.exists when: not stat_results is skipped and stat_results.stat.exists

View File

@ -39,7 +39,7 @@
failed_when: failed_when:
- error_on_failure is defined - error_on_failure is defined
- error_on_failure - error_on_failure
- requirements_install|failed - requirements_install is failed
# Build an sdist. This is needed for pbr projects that may expect # Build an sdist. This is needed for pbr projects that may expect
# the ChangeLog to have been generated. # the ChangeLog to have been generated.
@ -54,7 +54,7 @@
failed_when: failed_when:
- error_on_failure is defined - error_on_failure is defined
- error_on_failure - error_on_failure
- sdist_results|failed - sdist_results is failed
# Try installing current repo in case it needs to be available for # Try installing current repo in case it needs to be available for
# example for version number calculation. Ignore any failures here. # example for version number calculation. Ignore any failures here.
@ -71,4 +71,4 @@
failed_when: failed_when:
- error_on_failure is defined - error_on_failure is defined
- error_on_failure - error_on_failure
- install_package_results|failed - install_package_results is failed