Skip to content

feat: add build-context support - #2020

Open
0Itsuki0 wants to merge 1 commit into
apple:mainfrom
0Itsuki0:main
Open

feat: add build-context support#2020
0Itsuki0 wants to merge 1 commit into
apple:mainfrom
0Itsuki0:main

Conversation

@0Itsuki0

@0Itsuki0 0Itsuki0 commented Jul 26, 2026

Copy link
Copy Markdown

Add support for named build contexts, equivalent to Docker/Buildx and Podman --build-context name=value.

Type of Change

  • New feature

Motivation and Context

Supporting named build contexts : resolve #1930

Supported formats:

  • name=/absolute/or/relative/local/path
  • name=docker-image://xxx
  • name=oci-layout:/path/to/layout (with or without digest)
  • URL/Git

Testing

  • Tested locally
  1. Check out the container fork for enabling build-context option
  2. build the container by running make all && make install
  3. Check out builder shim fork
  4. build the shim image by running container build -t builder .
  5. update build image in container config at ~/.config/container/config.toml
[build]
image = "builder:latest"
  1. Use the BuildContextTest.zip to test out all 4 scenarios above + when a regular build where no named context is specified.

@0Itsuki0 0Itsuki0 changed the title feat: add build-context support feat: add build-context support #1930 Jul 27, 2026
@0Itsuki0 0Itsuki0 changed the title feat: add build-context support #1930 feat: add build-context support Jul 27, 2026
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.

[Request]: Support Docker/BuildKit named build contexts in container build

1 participant