gitlab: Propagate stack name to downstream build jobs (#29019)

It will be useful for metrics gathering and possibly debugging to
have this environment variable available in the runner pods that
do the actual rebuilds.
This commit is contained in:
Scott Wittenburg 2022-02-17 13:36:48 -07:00 committed by GitHub
parent e7e6a16064
commit 38643dcd7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1114,6 +1114,10 @@ def generate_gitlab_ci_yaml(env, print_summary, output_file,
if pr_mirror_url:
output_object['variables']['SPACK_PR_MIRROR_URL'] = pr_mirror_url
spack_stack_name = os.environ.get('SPACK_CI_STACK_NAME', None)
if spack_stack_name:
output_object['variables']['SPACK_CI_STACK_NAME'] = spack_stack_name
sorted_output = {}
for output_key, output_value in sorted(output_object.items()):
sorted_output[output_key] = output_value