Repository navigation
Description
Kiri version and system
Kiri built from source: main at f9cd271, with #731 on top. #731 doesn't touch builds. macOS 27.2.1 (Apple M4 Pro); the docker CLI inside the container is 29.9.3 with buildx v0.39.0 (docker:cli).
What you did
A docker CLI in a container, talking to Kiri through the mounted socket, as CI runners and self-hosted platforms (Dokploy, #603) do:
docker --context kiri run --rm -v /var/run/docker.sock:/var/run/docker.sock docker:cli sh -c '
mkdir /b && cd /b && printf "FROM alpine\nRUN echo hi > /x\n" > Dockerfile
docker build -t probe-incontainer .
docker image inspect probe-incontainer --format "{{.Id}}"'What happened
The build succeeds, but the image is not in Kiri's store:
#0 building with "default" instance using docker-container driver
WARNING: No output specified with docker-container driver. Build result will only remain in the build cache. To push result image into registry use --push or to load image into docker use --load
Error response from daemon: No such image: probe-incontainer
What you expected instead
The image in the engine's store, as with Docker Engine 29.8.2 (OrbStack), running the same command:
#0 building with "default" instance using docker driver
#6 naming to docker.io/library/probe-incontainer:latest done
sha256:91df84d17208240a60d2037450b8a76e9f73d…
Anything else
-
Why it happens: Kiri's
/_pingsaysBuilder-Version: 1, since there's no BuildKit inside the engine (Built-in builder: Serve Docker's build endpoints (/session, /grpc) so buildx works with its docker driver #49). So buildx in the container can't use itsdockerdriver. It makes its own builder calleddefault, with thedocker-containerdriver (it startsbuildx_buildkit_default), and withoutdefault-load. The result stays in that builder's cache. -
Why the Mac's own CLI works:
kiri setupmakes thekiri-buildbuilder with--driver-opt default-load=true(crates/kiri/src/builds.rs). A CLI in a container has nothing like it. -
A builder of your own doesn't help:
docker buildkeeps using thedefaultbuilder, even afterdocker buildx create --driver-opt default-load=trueanddocker buildx use --defaulton that builder (tried in Dokploy's container: CLI 28.5.2, buildx 0.39.0). -
Workaround:
DOCKER_BUILDKIT=0(Kiri's classicPOST /build) puts the image in the store:$ docker --context kiri run --rm -e DOCKER_BUILDKIT=0 -v /var/run/docker.sock:/var/run/docker.sock docker:cli sh -c '… docker build -t probe-incontainer . …' Successfully tagged probe-incontainer:latestThat is what Dokploy needed to deploy from Git in the Swarm on one node: services, stacks, secrets and configs, so Dokploy runs #731 test. The classic builder is deprecated in the CLI, though, and buildx-only options don't work with it.
-
Fixes I can see:
- Built-in builder: Serve Docker's build endpoints (/session, /grpc) so buildx works with its docker driver #49 (BuildKit in the engine,
/sessionand/grpc) would fix this at the root, since buildx would use itsdockerdriver. - Until then, Kiri could load what such a builder produces. buildx creates its container through Kiri (
POST /containers/create?name=buildx_buildkit_default), just as it doeskiri-build0, whichcreate_for_buildxalready handles. But loading the image is the client's choice (--load), so the daemon alone may not be able to.
Happy to look into it if one of these is wanted.
- Built-in builder: Serve Docker's build endpoints (/session, /grpc) so buildx works with its docker driver #49 (BuildKit in the engine,
Activity
Builder: load images built by containerized Docker CLIs into Kiri's s…
libracoder commentedon Nov 24, 2026
Fixed in #899.
Builder: load images built by containerized Docker CLIs into Kiri's s…