Skip to content

build: vendor API reference data to speed up site builds - #26182

Merged
dvdksn merged 6 commits into
docker:mainfrom
dvdksn:codex/vendor-api-reference-data
Sep 25, 2026
Merged

dvdksn merged 6 commits into
docker:mainfrom
dvdksn:codex/vendor-api-reference-data

Conversation

@dvdksn

@dvdksn dvdksn commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

API generation introduced in #26048 added roughly five minutes to site builds: median successful main-branch build-workflow duration rose from 4m 05s to 8m 48s across September 3–25. The pre-build command took 4m 41s–4m 53s in each of four jobs on the merge commit.

Vendor the generated presentation model in data/api-reference.json, mark it as generated, and let Docker, Netlify, and local Hugo builds consume it directly. Keep the existing rendered-output checks.

Move generator tests, strict spec validation, and a byte-for-byte regeneration check into docker buildx bake validate-api-reference, inheriting the shared Docker base stage. The target uses the pinned Vacuum release binary with Dockerfile ADD checksum verification and archive extraction instead of compiling Vacuum from source. The existing build workflow runs this target alongside the other validation matrix entries. Only this matrix entry is advisory; its failures do not block site builds or deployment.

Validated locally with the Docker target, rejection of deliberately stale data, repeatable generation across directories, a production Hugo build and verification of 453 API HTML/Markdown page pairs, workflow syntax checks, and scoped documentation lint. The prebuilt-binary CI check passed in 1m 40s, down from 5m 15s with source compilation. Remote layer-cache settings were subsequently removed; local Go cache mounts remain.

Generated by Codex

API generation added roughly five minutes to site builds and ran independently in multiple validation jobs. Vendor the generated JSON and move tests, spec validation, and regeneration comparison into a separate advisory Docker Bake workflow.

Mark the JSON as generated and update Docker, Netlify, local builds, and contributor instructions to consume the vendored data.
@netlify

netlify Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for docsdocker ready!

Name Link
🔨 Latest commit 3779010
🔍 Latest deploy log https://app.netlify.com/projects/docsdocker/deploys/6ab6a06386c24700081af4bf
😎 Deploy Preview https://deploy-preview-26182--docsdocker.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions github-actions Bot added the area/api Relates to Docker API docs label Sep 25, 2026
@dvdksn dvdksn added the status/review Pull requests that are ready for review label Sep 25, 2026
@github-actions github-actions Bot added area/release Relates to CI or deployment hugo Updates related to hugo area/config ci ci updates labels Sep 25, 2026
@dvdksn
dvdksn requested a review from a team September 25, 2026 05:38
The advisory check spent nearly four minutes installing Vacuum from source on a fresh CI runner. Download the pinned release binary with architecture-specific SHA-256 verification and preserve Docker build layers in the GitHub Actions cache.
Replace the separate API workflow with an entry in the existing validation matrix. Keep only the API entry advisory and preserve its Docker layer cache settings.
Use ADD with checksum verification and archive extraction for the pinned Vacuum release on AMD64 and ARM64. Remove remote cache import/export from the validation matrix while retaining local Go cache mounts.
Install Vacuum on PATH in the Dockerfile and have the script invoke it normally. Remove tool bootstrapping and private binary paths, run the repository generator through go run, and document the local prerequisites.
Remove the redundant warning annotation and job summary. The Bake action already captures validation output and the failing step status.
@dvdksn
dvdksn merged commit 2b12ac0 into docker:main Sep 25, 2026
15 checks passed
@dvdksn
dvdksn deleted the codex/vendor-api-reference-data branch September 25, 2026 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/api Relates to Docker API docs area/config area/release Relates to CI or deployment ci ci updates hugo Updates related to hugo status/review Pull requests that are ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants