ignore errors if set zuul_site_mirror_fqdn fails

It can be that zuul_site_mirror_fqdn env variable will not be set,
in this case the whole job will fail, instead of simply not configuring
mirrors during image build. With this patch, if set_fact fails, mirrors
simply will not be configured during image build, as planned in lines 62
and 88 in this playbook

Change-Id: I049c696c7fb0d7cadb527a9f17dd01a42a671baa
This commit is contained in:
Kostiantyn Kalynovskyi 2019-07-01 16:15:37 +03:00
parent 24841d6dea
commit 1ef750c8bb

View File

@ -14,6 +14,7 @@
- name: set zuul_site_mirror_fqdn from env var if not defined - name: set zuul_site_mirror_fqdn from env var if not defined
when: zuul_site_mirror_fqdn is not defined when: zuul_site_mirror_fqdn is not defined
ignore_errors: True
set_fact: set_fact:
zuul_site_mirror_fqdn: "{{ lookup('env','zuul_site_mirror_fqdn') }}" zuul_site_mirror_fqdn: "{{ lookup('env','zuul_site_mirror_fqdn') }}"