File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 1010
1111env :
1212 TARGET_PLATFORMS : linux/amd64,linux/arm64
13+ COMPOSE_DOCKER_CLI_BUILD : ' 1'
14+ DOCKER_BUILDKIT : ' 1'
1315
1416jobs :
1517 build_images :
@@ -215,11 +217,17 @@ jobs:
215217 }
216218
217219 rc=0
220+ REMOTE_DIGEST="$(skopeo inspect --raw "$IMAGE_URI" | skopeo manifest-digest /dev/stdin)"
221+ if [ "$REMOTE_DIGEST" != "${IMAGE_DIGEST}" ]; then
222+ echo 'generated a diferent manifest than '"${IMAGE_DIGEST}"': '"$REMOTE_DIGEST"
223+ exit 2
224+ fi
225+ docker pull -q "$(echo "$IMAGE_URI" | rev | cut -d: -f2- | rev )@${IMAGE_DIGEST}"
218226 for platform in $(echo $TARGET_PLATFORMS | tr , '\n')
219227 do
220228 docker pull --platform $platform -q "$IMAGE_URI"
229+ >&2 printf 'pulled %s (%s)\n' "$IMAGE_TAG" "$platform"
221230 done
222- docker pull -q "$IMAGE_URI"
223231 container_id="$(docker run --detach -p 8080:8080 --rm $IMAGE_URI)" || rc=$?
224232 if [ $rc -ne 0 ]; then
225233 printf 'docker run failed (return code '$rc')!\n' | >&2 tee \
You can’t perform that action at this time.
0 commit comments