Rather than quitting if there are no labels defined, we can instead
use the agent name (e.g. "centos7-2c-1g") as the default label. This
recreates the functionality of the groovy scripts previously used.
Issue: RELENG-3863
Change-Id: I3817cca81358fa151fdeb1bbc8516df983327965
Signed-off-by: Eric Ball <eball@linuxfoundation.org>
if "volume_size" not in section_all_machines:
section_all_machines.update(volume_size="10")
if "labels" not in section_all_machines:
- print("LABELS not Set in builder config")
- print(section_all_machines)
- exit(1)
+ # "section" is the name of the cloud agent, which is the default label
+ section_all_machines.update(labels=section)
j2_template = Template(machinetemplate)
section_all_machines.update(name_prefix=name_prefix)
--- /dev/null
+---
+fixes:
+ - |
+ When running create_jenkins_clouds_openstack_yaml.py, rather than quitting
+ if there are no labels defined, we can instead use the agent name
+ (e.g. "centos7-2c-1g") as the default label. This recreates the
+ functionality of the groovy scripts previously used.