From 2d2ba0d81ece119f5b2f9ecc3212bb9f51762229 Mon Sep 17 00:00:00 2001 From: sebthom Date: Wed, 12 Nov 2025 19:05:47 +0100 Subject: [PATCH] fix: curl of hack/dind script fails as of docker 29 --- image/Dockerfile | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/image/Dockerfile b/image/Dockerfile index 74f74b1..9e95781 100644 --- a/image/Dockerfile +++ b/image/Dockerfile @@ -183,6 +183,16 @@ RUN --mount=type=secret,id=github_token,required=false --mount=type=bind,source= else docker_version=$(docker --version | cut -d ' ' -f3 | cut -d ',' -f1) dind_hack_url="https://raw.githubusercontent.com/moby/moby/v${docker_version}/hack/dind" + # Check if it exists; if not, try the new prefix (docker-vX.Y.Z) + if ! curl -o /dev/null -f -s "$dind_hack_url"; then + alt_url="https://raw.githubusercontent.com/moby/moby/docker-v${docker_version}/hack/dind" + if curl -o /dev/null -f -s "$alt_url"; then + dind_hack_url="$alt_url" + else + echo "❌ Could not find dind hack script for Docker version ${docker_version}" >&2 + exit 1 + fi + fi echo "Downloading [$dind_hack_url]..." curl "$dind_hack_url" -o /usr/local/bin/dind-hack chmod +x /usr/local/bin/dind-hack