Skip to content

Commit

Permalink
jobs/release: fix --arch parameter to cosa push-container-manifest
Browse files Browse the repository at this point in the history
What I had wasn't properly expanding the `basearch` groovy variable
and was passing `$basearch` directly to bash and failing with
unbound variable. There is some code right below this that uses
collect to do the same thing so let's just re-use that here.

Fixes 08dcb09.
  • Loading branch information
dustymabe committed Sep 14, 2022
1 parent 08dcb09 commit 46a5be4
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions jobs/release.Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -178,15 +178,12 @@ podTemplate(cloud: 'openshift', label: pod_label, yaml: pod) {
stage("Push OSContainer Manifest") {
// Ship a manifest list containing all requested architectures.
withCredentials([file(credentialsId: 'oscontainer-secret', variable: 'OSCONTAINER_SECRET')]) {
def archparams = ''
for (basearch in basearches) {
archparams += ' --arch=${basearch}'
}
def arch_args = basearches.collect{"--arch ${it}"}.join(" ")
shwrap("""
cosa push-container-manifest --auth=\${OSCONTAINER_SECRET} \
--repo=${quay_registry} --tag=${params.STREAM} \
--artifact=ostree --metajsonname=base-oscontainer \
--build=${params.VERSION} ${archparams}
--build=${params.VERSION} ${arch_args}
""")
}
}
Expand Down

0 comments on commit 46a5be4

Please sign in to comment.