fix: preserve Docker feature flags when enabling CDI - #2049
Open
git-jxj wants to merge 1 commit into
Open
Conversation
Signed-off-by: xinjun.jiang <[email protected]>
git-jxj
force-pushed
the
fix/preserve-docker-features-when-enabling-cdi
branch
from
September 8, 2026 06:15
1f25bcd to
e3184b6
Compare
Member
|
/ok to test e3184b6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Running
nvidia-ctk runtime configure --runtime=docker --enable-cdiagainst a daemon.json with existing feature flags replaces them with onlycdi: true. For example,containerd-snapshotter: trueandbuildkit: falsedisappear.Docker configuration is decoded into
map[string]any, butEnableCDIasserts the features entry asmap[string]bool. Use the decoded map type so existing settings survive while CDI is enabled.Add file-based tests for missing/empty features, existing true and false flags, CDI already enabled or disabled, and repeated load/update/save operations.
Checklist
make test) — the full suite has the baseline failures described below.make lint)Testing
go test -race ./pkg/config/... ./cmd/nvidia-ctk/runtime/... -count=1passed.make lint: 0 issues.make testhas the same four failing packages and nine failing subtests on unmodified upstream and this branch: installer, installer/toolkit, modifier, and nvcdi. These involve missing test driver libraries and CSV hook expectation differences; the full suite is not reported as passing.