Skip to content

Commit 17ec44e

Browse files
authored
chore(goreleaser): Fix error handling during release (#3950)
* chore(goreleaser): Fix error handling during release * Check for number of architectures * Try matching array
1 parent 27fff3e commit 17ec44e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/weekly-release.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ jobs:
6161

6262
- name: Push per architecture images and create multi-arch manifest
6363
run: |
64+
set -eu -o pipefail
6465
set +x
6566
IMAGE_AMMENDS=()
6667
@@ -72,6 +73,15 @@ jobs:
7273
IMAGE_AMMENDS+=( "--amend" "${new_image}" )
7374
done
7475
76+
if [[ ! " ${IMAGE_AMMENDS[*]} " =~ -amd64 ]]; then
77+
echo "expected to contain an amd64 image"
78+
exit 1
79+
fi
80+
if [[ ! " ${IMAGE_AMMENDS[*]} " =~ -arm64 ]]; then
81+
echo "expected to contain an arm64 image"
82+
exit 1
83+
fi
84+
7585
docker manifest create "grafana/pyroscope:${WEEKLY_IMAGE_TAG}" "${IMAGE_AMMENDS[@]}"
7686
docker manifest push "grafana/pyroscope:${WEEKLY_IMAGE_TAG}"
7787
- name: Get github app token (valid for an hour)

0 commit comments

Comments
 (0)