Skip to content

CI: mirror base images to GHCR, pinned by digest (step 1 of 2) - #203

Merged
ndbroadbent merged 2 commits into
mainfrom
ci/mirror-base-images
Dec 4, 2026
Merged

ndbroadbent merged 2 commits into
mainfrom
ci/mirror-base-images

Conversation

@ndbroadbent

@ndbroadbent ndbroadbent commented Dec 4, 2026 •

Copy link
Copy Markdown
Member

Step 1 of 2 in taking Docker Hub out of CI's critical path. Docker Hub returned 502s from auth.docker.io and failed #194's journeys and images jobs.

  • .github/mirror.txt lists every image CI pulls from Docker Hub, pinned by digest: postgres:17 (services), rustfs (S3 for tests), rust:1.99.1-trixie (the release-bins container and the Dockerfiles), node:24-trixie-slim and debian:trixie-slim (the Dockerfiles), amazon/aws-cli (scripts/ci/visual.sh), and moby/buildkit (setup-buildx).
  • .github/workflows/mirror.yml copies each image with crane copy to ghcr.io/docspring/mirror/<name>:<tag>. It retries Docker Hub errors with backoff and fails unless the copy has the expected digest. It runs on main when the list changes, weekly to repair a deleted copy, and by hand. Only main writes the mirror. crane comes from Google's release, checksum verified, with no third-party action.
  • Digests are kept. crane copy copies the whole multi-platform index, so ghcr.io/docspring/mirror/postgres@sha256:97fb… is byte for byte the same image as postgres@sha256:97fb… on Docker Hub.
  • The mirror should be public. Packages that a public repository's workflow creates inherit its visibility, so CI and forks pull without logging in. I'll check that once it has run.

Step 2, a follow-up PR once this has run on main: point ci.yml's services and containers, the docker run lines, the Dockerfiles' FROM lines and setup-buildx's BuildKit image at the mirror by digest, and retry the remaining pulls.

Talira search: nothing listed fits better than GitHub's own registry (search 01a240ab-3a06-24da-d4cc-1af2783308b7). Self-hosted registries and pull-through caches (Harbor, zot, Quay, Distribution, Artifactory) would be a new thing to run, for runners that are already on GitHub.


Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

…inned by digest

A Docker Hub outage (502s from auth.docker.io) failed #194's journeys and images jobs. This workflow copies the
images CI pulls to GitHub's registry with crane, keeping their digests; a follow-up points CI at the copies.
@ndbroadbent
ndbroadbent force-pushed the ci/mirror-base-images branch from 7821049 to a13ce8e Compare December 4, 2026 11:16
@ndbroadbent
ndbroadbent merged commit 9d46faf into main Dec 4, 2026
16 checks passed
@ndbroadbent
ndbroadbent deleted the ci/mirror-base-images branch December 4, 2026 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant