Feature/node data broker validating admission policy - #439
Open
Shankar-v27 wants to merge 1 commit into
Open
Conversation
…lege (NVIDIA#386) Signed-off-by: Shankar V <shankarvelmurugan2018@gmail.com>
Contributor
Greptile SummaryThis PR makes the Topograph Helm chart’s API-server RBAC conditional on the selected provider and engine.
Confidence Score: 5/5The PR appears safe to merge, with the rendered permissions matching the Kubernetes API operations required by the covered provider and engine configurations. The conditional resource rules preserve Node get and update access for the Kubernetes engine, list and patch access for Slinky, provider-specific pod and DaemonSet access for InfiniBand, and NFD-specific resources while cleanly omitting unused RBAC. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
C[Provider and engine configuration] --> P{Pods required?}
C --> E{Pod exec required?}
C --> N{Node access required?}
C --> D{DaemonSet access required?}
C --> M{ConfigMap access required?}
P --> R{Any Kubernetes permission required?}
E --> R
N --> R
D --> R
M --> R
R -->|Yes| CR[Render ClusterRole and ClusterRoleBinding]
R -->|No| OMIT[Omit cluster-scoped RBAC]
C --> F{NFD engine?}
F -->|Yes| NS[Render NFD namespaced Role and RoleBinding]
F -->|No| DONE[No NFD-specific RBAC]
Reviews (1): Last reviewed commit: "fix(chart): gate Topograph API server RB..." | Re-trigger Greptile |
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
Closes #386
This PR updates the Topograph Helm chart to follow the principle of least privilege by rendering only the RBAC permissions required for the configured provider and engine.
Summary
Nodeverbs based on the enabled providers and engines.pods,pods/exec,daemonsets,configmaps, etc.) only when they are required.ClusterRoleandClusterRoleBindingwhen no Kubernetes API permissions are needed.Motivation
Previously, the chart could grant permissions that were unnecessary for a given deployment configuration. This change minimizes the RBAC footprint by ensuring only the permissions required for the selected configuration are rendered, reducing the attack surface while preserving existing functionality.
Testing
mainand resolved merge conflicts.Checklist
git commit -s).