[WIP] : remove unnecessary permissions, add validating-admissions-policies#2202
Draft
rahulait wants to merge 1 commit intoNVIDIA:mainfrom
Draft
[WIP] : remove unnecessary permissions, add validating-admissions-policies#2202rahulait wants to merge 1 commit intoNVIDIA:mainfrom
rahulait wants to merge 1 commit intoNVIDIA:mainfrom
Conversation
eb025d7 to
55e699c
Compare
rahulait
commented
Mar 11, 2026
| - name: gpu-operator-service-account | ||
| expression: request.userInfo.username == 'system:serviceaccount:{{ .Release.Namespace }}:gpu-operator' | ||
| - name: target-namespace | ||
| expression: object.metadata.name in ['{{ .Release.Namespace }}', 'nvidia-gpu-operator'] |
Contributor
Author
There was a problem hiding this comment.
need inputs here if these are the only namespaces we label or there can be others as well in case of openshift
rahulait
commented
Mar 11, 2026
| @@ -0,0 +1,141 @@ | |||
| {{- if .Capabilities.APIVersions.Has "admissionregistration.k8s.io/v1/ValidatingAdmissionPolicy" }} | |||
Contributor
Author
There was a problem hiding this comment.
This can be further restricted to be installed if someone requests validatingadmissionpolicy guardrails in values.yaml. I haven't added added that and looking for feedback if we should do something like that or let these be always installed if supported by k8s.
Signed-off-by: Rahul Sharma <rahulsharm@nvidia.com>
55e699c to
76ad771
Compare
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
This is still work in progress. PR will be updated as we get more feedback.
Key changes include:
a. Restrict to certain runtime handlers when creating a runtime class
b. Restrict to certain node labels when labeling nodes
c. Restrict to certain labels that can be added to namespaces
Openshift specific OLM bundle generation still needs to be updated in the PR
Checklist
make lint)make validate-generated-assets)make validate-modules)Testing