Fix SUSE gate overrides outside gates
When storing the nodepool information task into suse mirror, the resulting variable could be storing ansible information, not only stdout. That could lead to malformed urls for the variable, when the check is skipped outside gates. See the value of a repo, containing ``opensuse_mirror`` here: "{'skipped': True, 'skip_reason': 'Conditional result was False', 'changed': False}/distribution/leap/42.3/repo/oss/" Change-Id: Idfd3c233c2239b642154960b536abe1f7fca7942
This commit is contained in:
parent
8fc92038f1
commit
e01a2aecca
@ -87,7 +87,7 @@
|
||||
echo "${NODEPOOL_OPENSUSE_MIRROR}"
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: opensuse_mirror
|
||||
register: _opensuse_mirror
|
||||
delegate_to: localhost
|
||||
when:
|
||||
- ansible_pkg_mgr == 'zypper'
|
||||
@ -97,7 +97,7 @@
|
||||
|
||||
- name: Set a fact to override the openSUSE mirror URL when in nodepool
|
||||
set_fact:
|
||||
opensuse_mirror: "{{ opensuse_mirror.stdout }}"
|
||||
opensuse_mirror: "{{ _opensuse_mirror.stdout }}"
|
||||
# OpenStack infra doesn't mirror OBS repos so use the upstream one
|
||||
opensuse_mirror_obs: "http://download.opensuse.org"
|
||||
when:
|
||||
|
Loading…
Reference in New Issue
Block a user