Skip to content

Support BuildKit build secrets - #854

Merged
apocas merged 1 commit into
masterfrom
codex/buildkit-secrets
Oct 27, 2026
Merged

apocas merged 1 commit into
masterfrom
codex/buildkit-secrets

Conversation

@apocas

@apocas apocas commented Oct 27, 2026

Copy link
Copy Markdown
Owner

BuildKit builds can now receive a secrets map of IDs to Buffers through the session's Secrets/GetSecret RPC. This replaces #821 while preserving the session health service added in #847.

The build request copies the caller's options before excluding secrets from the URL, so the provider retains the values and callers can reuse their options. Missing or inherited IDs return NOT_FOUND, allowing optional secret mounts to work; invalid values and secrets larger than 500 KiB return INVALID_ARGUMENT.

Validation: 29 targeted tests passed locally on Node 24 against Docker Engine 29.9.2. Coverage includes binary and empty secrets, missing and invalid values, session health and registry authentication, callback and Promise builds, secret exclusion from request options and logs, and secret mount removal after the build step. Existing BuildKit, regular build, progress, and utility checks also passed.

Replace the implementation proposed in #821 with session-based secret delivery that preserves caller options, handles optional missing secrets, and retains session health checks. Add RPC and Docker integration coverage for callback and promise builds.
@apocas
apocas merged commit 446e07c into master Oct 27, 2026
15 checks passed
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