Skip to content

[gpu-op] GPUCluster silently ignores daemonsets.podSecurityContext #3203

Open

Description

@rahulait

GPUCluster accepts spec.daemonsets.podSecurityContext, but does not propagate it to the Pod specs of its DRA driver, DCGM, DCGM exporter, or validator DaemonSets.

For example:

spec:
  daemonsets:
    podSecurityContext:
      seLinuxOptions:
        type: spc_t
        level: s0

Expected behavior

The configured context appears under spec.template.spec.securityContext in the managed DaemonSets, while preserving required container-level settings such as privileged: true and explicit runAsUser values.

Actual behavior

All four GPUCluster DaemonSet templates omit the pod security context. The configuration is accepted but silently has no effect. The equivalent configuration is honored through ClusterPolicy.

Verification

Verified against main at 9339140ceff2b60ca6f2c8e56d15d253044c30f4:

  • Rendering each of the four GPUCluster DaemonSets drops the supplied context.
  • A ClusterPolicy control preserves it.
  • Rendering the upstream DRA driver v0.5.1 chart preserves the supplied context.

Runtime impact depends on the cluster’s security configuration; these checks establish the configuration omission.

Related implementations

GPU Operator added pod security context support for ClusterPolicy DaemonSets and NVIDIADriver in PR #2120. Later, PR #2703 fixed forwarding daemonsets.podSecurityContext from Helm values into ClusterPolicy.

Upstream DRA driver v0.5.1 also supports this configuration:

Suggested fix

Render the common pod security context into the four GPUCluster DaemonSets and add regression coverage confirming that pod settings and required container-level security settings are both preserved.

Activity

  1. added
    needs-triage
    on Nov 9, 2026
  2. added
    good-first-issue
    and removed
    needs-triage
    on Nov 9, 2026
  3. dundysm commented on Nov 10, 2026

    @dundysm

    hi @rahulait, i'd like to take this one. plan: forward daemonsets.podSecurityContext onto the dra driver, dcgm, dcgm exporter and validator pod specs, keep the required container level privileged / runAsUser settings, and add render tests with clusterpolicy as the control. could you add accepted and assign it to me? happy to follow up on #2843 here.

  4. rahulait commented on Nov 10, 2026

    @rahulait
    ContributorAuthor

    @dundysm sure, sounds good to me.

  5. added a commit that references this issue on Nov 17, 2026
    f555964
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

good-first-issue

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions