Skip to content

fix(docker): pull the BuildKit frontend via mirror.gcr.io - #3008

Merged
vpetersson merged 3 commits into
masterfrom
fix/dockerfile-frontend-mirror
Jun 7, 2026
Merged

fix(docker): pull the BuildKit frontend via mirror.gcr.io#3008
vpetersson merged 3 commits into
masterfrom
fix/dockerfile-frontend-mirror

Conversation

@vpetersson

@vpetersson vpetersson commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

Issues Fixed

CI builds intermittently fail with failed to resolve source metadata for docker.io/docker/dockerfile:1.4 … i/o timeout (e.g. the Generate OpenAPI Schema run on the Sentry PR) because the # syntax= directive still pulls the BuildKit frontend from Docker Hub.

Description

Two changes to the # syntax= directive in the four Dockerfile templates (server, viewer, redis, test):

  1. Pull via mirror.gcr.io — this was the last Docker Hub pull in the build pipeline (base images already use mirror.gcr.io/library/debian; bun/uv come from ghcr.io). Verified the mirror serves the same multi-arch manifest list.
  2. Bump the frontend pin 1.4 → 1.24 — 1.4 is from May 2022; this picks up four years of frontend bugfixes while keeping the minor-pin convention. No template uses syntax newer than --mount=type=cache.

Validated by building the rendered redis image locally against mirror.gcr.io/docker/dockerfile:1.24.

Checklist

  • I have performed a self-review of my own code.
  • New and existing unit tests pass locally and on CI with my changes.
  • I have done an end-to-end test for Raspberry Pi devices.
  • I have tested my changes for x86 devices.
  • I added a documentation for the changes I have made (when necessary).

🤖 Generated with Claude Code

The `# syntax=docker/dockerfile:1.4` directive made every image build
fetch the frontend from registry-1.docker.io — the last remaining
Docker Hub dependency (base images already come from mirror.gcr.io,
bun/uv from ghcr.io). Docker Hub pulls from shared GitHub runner IPs
intermittently time out, failing CI before the build even starts.

Re-point the directive at Google's pull-through cache, which serves
the same multi-arch manifest list. The version pin stays for frontend
reproducibility.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@vpetersson
vpetersson requested a review from a team as a code owner June 7, 2026 05:15
@vpetersson vpetersson self-assigned this Jun 7, 2026
@vpetersson
vpetersson requested a review from Copilot June 7, 2026 05:15

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR reduces intermittent CI build failures by moving the Dockerfile BuildKit frontend (# syntax=) pull off Docker Hub and onto mirror.gcr.io, aligning it with the rest of the pipeline’s mirrored base-image usage.

Changes:

  • Updated # syntax=docker/dockerfile:1.4 to # syntax=mirror.gcr.io/docker/dockerfile:1.4 across the Dockerfile Jinja2 templates for server, viewer, redis, and test images.
  • Ensures the BuildKit frontend image is no longer the last remaining Docker Hub dependency in the build pipeline.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
docker/Dockerfile.viewer.j2 Points BuildKit frontend (# syntax) at mirror.gcr.io for viewer image builds.
docker/Dockerfile.test.j2 Points BuildKit frontend (# syntax) at mirror.gcr.io for test image builds.
docker/Dockerfile.server.j2 Points BuildKit frontend (# syntax) at mirror.gcr.io for server image builds.
docker/Dockerfile.redis.j2 Points BuildKit frontend (# syntax) at mirror.gcr.io for redis image builds.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

vpetersson and others added 2 commits June 7, 2026 05:21
1.4 dates to May 2022; 1.24 is the current release. Nothing in the
templates needs newer syntax (--mount=type=cache predates 1.4), so
this is purely picking up four years of frontend bugfixes. Keeps the
minor-pin convention — the tag floats only over patch releases.

Validated by building the rendered redis image against the mirrored
1.24 frontend.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
`docker build --check` with the 1.24 frontend flags the legacy
`ENV DEBIAN_FRONTEND noninteractive` form (LegacyKeyValueFormat) in
the test template — the only hit across all four templates. All
rendered Dockerfiles now lint clean against the new frontend.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@sonarqubecloud

sonarqubecloud Bot commented Jun 7, 2026

Copy link
Copy Markdown

@vpetersson
vpetersson merged commit 7fc57fe into master Jun 7, 2026
7 checks passed
@vpetersson vpetersson mentioned this pull request Jun 7, 2026
5 tasks
vpetersson added a commit that referenced this pull request Jun 7, 2026
- CalVer (YYYY.0M.MICRO); still June 2026, micro 1 -> 2
- Ships the Qt 6 video audio fix (#3001) — PulseAudio in the viewer
  container; videos were silent on pi4-64/pi5/x86/arm64 since the
  QtMultimedia migration
- Adds the arm64/Qt6 pi3-64 board and the Rock Pi 4 fleet (#2985)
- Page-load watchdog so a stalled fetch can't freeze the display
  (#3003), Sentry error tracking for the Django services (#3007)
- Redis data persisted to the mounted volume so device identity
  survives recreation (#2983); unpinner also rolls OS + supervisor
  updates (#2984)
- Streamed backup downloads (#3005), 12-hour AM/PM asset times
  (#3002), BuildKit frontend via mirror.gcr.io (#3008)

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
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.

2 participants