Skip to content

W3.6: an engine-neutral OCI-layout image store, oci-layout parents, and a tag-free engine import #36

Closed

Description

@aitrawog

W3.6 — one BuildKit build path: an engine-neutral OCI-layout image store

Part of opencharly/opencharly#481 (BuildKit as charly's one image builder).

Measured gap

The build drive still produces an engine-specific artefact and bridges it with a tag step:

Spike (measured on a, 2026-10-23, buildkit 0.34.1 / podman 6.1.4)

  • buildctl ... --output type=oci,name=<full-ref>,dest=x.tar writes, in index.json:
    io.containerd.image.name=<full-ref>, org.opencontainers.image.ref.name=<tag only>,
    org.opencontainers.image.created=<rfc3339>. podman load -i x.tar lands it tagged, no tag step.
  • The negative control — the same build without name= — lands Loaded image: sha256:… untagged/dangling.
  • A child solved with --oci-layout charly=<store> --opt context:<base-ref>=oci-layout://charly@sha256:<manifest>
    succeeds while the base ref's registry is unreachable; the same child without the override fails with
    dial tcp: lookup ghcr.invalid: no such host. That is the box-on-box proof: the layout, not the registry,
    supplies the parent.

Scope of this change (plugin-build)

  1. Export each built image with name=<FullTag>; write the archive into the charly image store — one OCI
    layout at $XDG_DATA_HOME/charly/images/, one index.json, each manifest annotated
    io.containerd.image.name=<FullTag> and org.opencontainers.image.created — and keep it as the canonical
    artefact.
  2. Materialise from the annotated archive into the run engine without a tag step, verifying the ref resolves
    through the engine capability table (no engine word literals in the code path).
  3. Wire buildkitdrive.Build.OCILayouts (sdk#433, tag v0.2026296.803) plus the named-context option so a
    parent present in the charly store is solved from oci-layout://charly@<digest>; the registry is a fallback
    only when the parent is absent locally.
  4. Keep --push as the second output (type=image,push=true).

Out of scope here, filed separately (cross-repo)

  • charly box build --engine needs spec.BuildRequest.Engine + a plugin-box flag — filed in plugin-box/spec.
  • --tag > box tag > defaults.tag > auto cannot be implemented in the drive alone: plugin-box pre-fills
    req.Tag with the computed CalVer, so an explicit --tag cannot be distinguished from auto — filed in plugin-box.
  • charly clean (keep_images) pruning of the charly image store lives in plugin-clean — filed there.
  • The ResolvePodEngine/ResolveContainerdTarget resolver is feat(deploykit): the W3.1 selection resolvers — engine, VM backend, containerd target sdk#457 (open, untagged); this change
    keeps the existing resolved-run-engine selection path and does not add a second selector.

Acceptance

  • OCI annotation proven with its negative control (both directions).
  • A box-on-box build with the parent in the charly store and the registry unreachable.
  • The layout imports into at least one engine.

Activity

  1. self-assigned this
    on Oct 23, 2026
  2. aitrawog commented on Oct 23, 2026

    @aitrawog
    ContributorAuthor

    CLAIM — W3.6 (containerd-crabbox-program/w36).

    Starting on feat/w36-buildkit-image-store off origin/main (1f3c659). Spike already proves the two
    mechanisms this change rests on (OCI io.containerd.image.name naming with its negative control; a
    registry-unreachable box-on-box solve through --oci-layout + a named context). Cross-repo gaps
    (--engine, --tag precedence, keep_images pruning, sdk RootData) are being filed separately and
    linked here.

    Agent: containerd-crabbox-program/w36 · session 8b1c01cf-7f79-4a75-bff8-240415a06208
    Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)

  3. aitrawog commented on Oct 23, 2026

    @aitrawog
    ContributorAuthor

    RESOLVED — W3.6 landed. #37 merged as c79ee55 (head f2ecf3b, tag
    v2026.296.1100), with the review-round polish carried in #38; the build-skill
    doc leg landed as opencharly/plugin-box#63.

    Delivered: the charly image store (engine-neutral OCI layout at $XDG_DATA_HOME/charly/images,
    io.containerd.image.name=<FullTag> + org.opencontainers.image.created per manifest), a tag-free
    engine import verified through the capability table, Build.OCILayouts wired as a named-context parent
    binding (registry-unreachable box-on-box proven with its failing control), and the removal of every
    engine word literal from the build path.

    Remaining cross-repo legs, filed: opencharly/sdk#458 (storekit data root), opencharly/plugin-box#61
    (--engine, --tag precedence), opencharly/plugin-clean#21 (keep_images pruning of the store),
    opencharly/sdk#457 (W3.1 resolvers; no second selector added).

    Agent: containerd-crabbox-program/w36 · session 8b1c01cf-7f79-4a75-bff8-240415a06208
    Assisted-by: Claude Code deepseek-v4.1-flash:cloud (fully tested and validated)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions