Skip to content

Commit

Permalink
Merge branch 'cleanup-role' into 'master'
Browse files Browse the repository at this point in the history
[RBAC] cleanup redundant and invalid Role permissions

See merge request nvidia/kubernetes/gpu-operator!1086
  • Loading branch information
tariq1890 committed May 31, 2024
2 parents a003b1e + 1473ff6 commit 58afc29
Show file tree
Hide file tree
Showing 24 changed files with 6 additions and 294 deletions.
8 changes: 0 additions & 8 deletions assets/gpu-feature-discovery/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- nodes
verbs:
- get
- list
- watch
8 changes: 0 additions & 8 deletions assets/state-device-plugin/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- nodes
verbs:
- get
- list
- watch
17 changes: 0 additions & 17 deletions assets/state-driver/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
1 change: 0 additions & 1 deletion assets/state-mig-manager/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,5 @@ rules:
- ""
resources:
- pods
- nodes
verbs:
- '*'
9 changes: 0 additions & 9 deletions assets/state-mps-control-daemon/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- nodes
verbs:
- get
- list
- watch

1 change: 0 additions & 1 deletion assets/state-node-status-exporter/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ rules:
- ""
resources:
- pods
- nodes
verbs:
- get
- list
7 changes: 0 additions & 7 deletions assets/state-operator-validation/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ rules:
- ""
resources:
- pods
- nodes
verbs:
- '*'
- apiGroups:
Expand All @@ -26,9 +25,3 @@ rules:
- daemonsets
verbs:
- '*'
- apiGroups:
- nvidia.com
resources:
- clusterpolicies/finalizers
verbs:
- '*'
8 changes: 0 additions & 8 deletions assets/state-sandbox-device-plugin/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- "get"
6 changes: 0 additions & 6 deletions assets/state-sandbox-validation/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- nodes
verbs:
- get
8 changes: 0 additions & 8 deletions assets/state-vgpu-manager/0200_role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,3 @@ rules:
- use
resourceNames:
- privileged
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- "get"
6 changes: 6 additions & 0 deletions assets/state-vgpu-manager/0210_clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,9 @@ rules:
- list
- patch
- watch
- apiGroups:
- ""
resources:
- pods/eviction
verbs:
- get
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-additional-configs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-full-spec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-gdrcopy-openshift.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-gdrcopy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-gds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-minimal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-openshift-drivertoolkit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-precompiled.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-rdma-hostmofed.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-rdma.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
17 changes: 0 additions & 17 deletions internal/state/testdata/golden/driver-vgpu-host-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@ rules:
- securitycontextconstraints
verbs:
- use
- apiGroups:
- ""
resources:
- pods
- pods/eviction
- nodes
verbs:
- '*'
- apiGroups:
- apps
resources:
- deployments
- daemonsets
- replicasets
- statefulsets
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
Loading

0 comments on commit 58afc29

Please sign in to comment.