diff --git a/hack/release-helper.sh b/hack/release-helper.sh index 8569c16be..722fbac0a 100755 --- a/hack/release-helper.sh +++ b/hack/release-helper.sh @@ -81,9 +81,6 @@ function tag_and_push_packages() { for staged_pkg_name in ${!staged_to_release[@]}; do release_pkg_name=${staged_to_release[${staged_pkg_name}]} - # pull the staged package - docker pull ${ghcr_repo}/${staged_pkg_name}:${release_candidate_sha} - # set tag prefix (if needed) release_tag_prefix= if [[ -v staged_to_release_tag_prefix[${staged_pkg_name}] ]]; then @@ -91,11 +88,23 @@ function tag_and_push_packages() { fi release_tag_full=${release_tag_prefix}${release_tag} - # tag it - docker tag ${ghcr_repo}/${staged_pkg_name}:${release_candidate_sha} ${ghcr_repo}/${release_pkg_name}:${release_tag_full} + for arch in x86_64 s390x; do + # pull the staged package + docker pull ${ghcr_repo}/${staged_pkg_name}:${release_candidate_sha}-${arch} + + # tag it + docker tag ${ghcr_repo}/${staged_pkg_name}:${release_candidate_sha}-${arch} \ + ${ghcr_repo}/${release_pkg_name}:${release_tag_full}-${arch} + + # push it (i.e. release it) + docker push ${ghcr_repo}/${release_pkg_name}:${release_tag_full}-${arch} + done - # push it (i.e. release it) - docker push ${ghcr_repo}/${release_pkg_name}:${release_tag_full} + # Publish the multi-arch manifest + docker manifest create ${ghcr_repo}/${release_pkg_name}:${release_tag_full} \ + --amend ${ghcr_repo}/${release_pkg_name}:${release_tag_full}-x86_64 \ + --amend ${ghcr_repo}/${release_pkg_name}:${release_tag_full}-s390x + docker manifest push ${ghcr_repo}/${release_pkg_name}:${release_tag_full} done }