nvidia-cdi-host
| Repo | box/github.com/opencharly/layer-nvidia:v2026.320.1938 |
NVIDIA CDI host layer — the containerd nvidia handler, a durable CDI spec, and the rootless client path Composes the nvidia candy and configures containerd for CDI: nvidia-ctk runtime configure –runtime=containerd (NO –enable-cdi — the key is ignored on containerd 2.x and emits a warning — and no –set-as-default) writes a drop-in at the layer-owned /etc/containerd/conf.d/99-nvidia.toml and records that directory in config.toml’s imports, so a default drop-in path refused as permission denied cannot leave a host silently unconfigured. Restarts containerd so the handler is SERVED, not merely written — containerd reads its config and drop-ins at startup. Enables and starts the toolkit’s nvidia-cdi-refresh.path and .service so /var/run/cdi/nvidia.yaml is regenerated at boot, on module load and when the toolkit changes, and exists on a fresh host before the checks run — a one-shot generate into /etc/cdi is a snapshot that goes stale on the first driver upgrade. Links the refreshed spec into the rootless client’s config dir (the user’s $XDG_CONFIG_HOME/cdi, default ~/.config/cdi -> /var/run/cdi/nvidia.yaml), because the rootless spec dirs are $XDG_CONFIG_HOME/cdi and $XDG_RUNTIME_DIR/cdi, never /etc/cdi. The checks gate on the DEVICE: crictl info serves the nvidia handler and nvidia-ctk cdi list reports nvidia.com/gpu=all; an exit code is not evidence because cdi list exits 0 on an invalid spec. Arch/omarchy only: a Fedora arm is additive and is not claimed until its own disposable bed exists (CONTAINERD-IMAGES.md §1).
Acceptance plan
Section titled “Acceptance plan”This candy’s plan: — the runnable spec charly check executes against a live deployment. check: steps are idempotent probes; run: steps change state.
| Intent | Step |
|---|---|
run |
configure containerd’s nvidia runtime handler with a drop-in this layer owns |
run |
restart containerd so the new handler is served, not merely written |
run |
enable and start the toolkit’s CDI refresh path and service |
run |
write the rootless CDI link helper |
run |
link the refreshed CDI spec into the rootless client’s config dir |
check |
the containerd drop-in registers the nvidia runtime handler |
check |
the drop-in does not carry the enable_cdi key containerd 2.x ignores |
check |
containerd’s config imports the drop-in directory |
check |
the CDI refresh path and service are enabled so the spec is regenerated, not snapshotted |
check |
the rootless client’s CDI spec link targets the refreshed spec |
check |
nvidia-ctk cdi list reports the nvidia.com/gpu=all device |
check |
crictl info serves the nvidia runtime handler |
check |
a rootful CDI injection runs nvidia-smi -L through nvidia.com/gpu=all |
check |
the rootless client resolves the same device through the linked refreshed spec |

