Separately set publish_site for docs promotion
Formatting a variable with a singular undefined parameter triggers an error, so instead add a separate task to set publish_site as a fact first, if it's been passed, and then just consume that in the subsequent task. This also basically reverts 2c96eae80d477fd974c0340bfaee3176a742326e as that solution introduced the regression we're fixing. Change-Id: I335bafab0d926a0f75971cdd0954a34911ae29c1
This commit is contained in:
parent
2c96eae80d
commit
cbad63e3b2
@ -52,9 +52,13 @@
|
||||
when: "zuul.branch != 'master'"
|
||||
set_fact:
|
||||
target_dict: "{{ afs.targets.branch }}"
|
||||
- name: Set publish site
|
||||
set_fact:
|
||||
publish_site: "{{ publish_site.format(zuul=zuul) }}"
|
||||
when: publish_site is defined
|
||||
- name: Set target path
|
||||
set_fact:
|
||||
target_dir: "{{ target_dict.path.format(zuul=zuul, publish_site=publish_site.format(zuul=zuul), special_publish_directory=special_publish_directory) }}"
|
||||
target_dir: "{{ target_dict.path.format(zuul=zuul, publish_site=publish_site, special_publish_directory=special_publish_directory) }}"
|
||||
- name: Adjust target path
|
||||
when: "target_dict.regex is defined"
|
||||
set_fact:
|
||||
|
Loading…
x
Reference in New Issue
Block a user