File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -157,13 +157,25 @@ jobs:
157157 IMAGE_NS : ${{ env.REGISTRY }}/${{ env.OWNER }}/web-gui
158158 run : |
159159 set -eu
160+ # GHCR is eventually consistent right after a push: manifest
161+ # creates can hit "manifest unknown" for a minute or two. Retry.
162+ sleep 30
160163 for daemon in $DAEMONS; do
161164 for variant in "$BASE" "$SHA_TAG"; do
162165 args=()
163166 for arch in $ARCHES; do
164167 args+=("--amend" "$IMAGE_NS/$daemon:$variant-$arch")
165168 done
166- docker manifest create "$IMAGE_NS/$daemon:$variant" "${args[@]}"
169+ attempt=1
170+ until docker manifest create "$IMAGE_NS/$daemon:$variant" "${args[@]}" >/dev/null; do
171+ if [ "$attempt" -ge 6 ]; then
172+ echo "::error::manifest create failed for $IMAGE_NS/$daemon:$variant after $attempt attempts"
173+ exit 1
174+ fi
175+ echo "attempt $attempt failed - retrying in 30s"
176+ sleep 30
177+ attempt=$((attempt + 1))
178+ done
167179 docker manifest push "$IMAGE_NS/$daemon:$variant"
168180 done
169181 done
You can’t perform that action at this time.
0 commit comments