Skip to content

solver: fix on-demand CDI device resolution - #7293

Draft
crazy-max wants to merge 1 commit into
moby:masterfrom
crazy-max:fix-cdi-on-demand-resolution
Draft

crazy-max wants to merge 1 commit into
moby:masterfrom
crazy-max:fix-cdi-on-demand-resolution

Conversation

@crazy-max

Copy link
Copy Markdown
Member

Entitlement validation currently adds every available on-demand CDI kind to a build device requests, even when the build requested an unrelated device. It also replaces the original requests with bare kind names, losing selectors such as =all and the optional flag. Required requests have the opposite problem where validation tries to resolve them before setup has registered the devices, so they fail with "required device … is not registered" without reaching the installer. This change retains only matching requests and preserves their names until setup completes. Explicit grants for on-demand kinds also stop failing premature resolution when a build requests registered devices alongside them. Existing permission checks for installed devices remain unchanged.

Only include on-demand devices requested by the build, preserving their
names, selectors, and optional flags. Defer resolution until setup has
registered the devices so required requests can reach the installer.

Skip unresolved on-demand kinds when checking explicit grants alongside
registered devices. Keep permission checks for installed devices intact.

Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
@crazy-max
crazy-max force-pushed the fix-cdi-on-demand-resolution branch from b675c35 to 016bab5 Compare October 17, 2026 14:50
@crazy-max crazy-max added this to the v0.35.0 milestone Oct 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant