Describe the bug
Hi team, I found there's inconsistency between cluster policy definition and helm-rendered cluster policy, which leads to ArgoCD keep reporting out-of-sync.
The issue is
The deprecated spec.cdi.default field is no longer rendered by the ClusterPolicy Helm template.
The rendered resource therefore contains:
However, the ClusterPolicy CRD still defines spec.cdi.default with a schema default of false.
The corresponding Go API definition also marks the field as deprecated and unused while retaining +kubebuilder:default=false.
After the rendered resource is applied, the Kubernetes API server adds the default:
spec:
cdi:
enabled: true
default: false
This creates a persistent difference:
Desired: spec.cdi.default is absent
Live: spec.cdi.default is false
Argo CD reports the ClusterPolicy as OutOfSync. Re-syncing cannot resolve the difference because the API server adds the field again after every apply.
To Reproduce
N/A
Expected behavior
These two files are kept in sync.
Environment (please provide the following information):
- GPU Operator Version: v26.3.3
- OS: N/A, unrelated
- Kernel Version: N/A, unrelated
- Container Runtime Version: N/A, unrelated
- Kubernetes Distro and Version: N/A, unrelated
Information to attach (optional if deemed irrelevant)
Collecting full debug bundle (optional):
N/A
Describe the bug
Hi team, I found there's inconsistency between cluster policy definition and helm-rendered cluster policy, which leads to ArgoCD keep reporting out-of-sync.
The issue is
The deprecated
spec.cdi.defaultfield is no longer rendered by the ClusterPolicy Helm template.The rendered resource therefore contains:
However, the ClusterPolicy CRD still defines
spec.cdi.defaultwith a schema default offalse.The corresponding Go API definition also marks the field as deprecated and unused while retaining
+kubebuilder:default=false.After the rendered resource is applied, the Kubernetes API server adds the default:
This creates a persistent difference:
Argo CD reports the
ClusterPolicyasOutOfSync. Re-syncing cannot resolve the difference because the API server adds the field again after every apply.To Reproduce
N/A
Expected behavior
These two files are kept in sync.
Environment (please provide the following information):
Information to attach (optional if deemed irrelevant)
kubectl get pods -n OPERATOR_NAMESPACEkubectl get ds -n OPERATOR_NAMESPACEkubectl describe pod -n OPERATOR_NAMESPACE POD_NAMEkubectl logs -n OPERATOR_NAMESPACE POD_NAME --all-containersnvidia-smifrom the driver container:kubectl exec DRIVER_POD_NAME -n OPERATOR_NAMESPACE -c nvidia-driver-ctr -- nvidia-smijournalctl -u containerd > containerd.logCollecting full debug bundle (optional):
N/A