Skip to content

Commit 0a6eb1b

Browse files
authored
Merge pull request #79 from datum-cloud/fix/metrics-auth-rbac
fix: add metrics auth RBAC to rbac_deployment component
2 parents 171587f + 2c12002 commit 0a6eb1b

File tree

3 files changed

+31
-0
lines changed

3 files changed

+31
-0
lines changed

config/rbac_deployment/kustomization.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,5 @@ kind: Component
33
resources:
44
- leader_election_role.yaml
55
- leader_election_role_binding.yaml
6+
- metrics_auth_role.yaml
7+
- metrics_auth_role_binding.yaml
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: rbac.authorization.k8s.io/v1
2+
kind: ClusterRole
3+
metadata:
4+
name: metrics-auth-role
5+
rules:
6+
- apiGroups:
7+
- authentication.k8s.io
8+
resources:
9+
- tokenreviews
10+
verbs:
11+
- create
12+
- apiGroups:
13+
- authorization.k8s.io
14+
resources:
15+
- subjectaccessreviews
16+
verbs:
17+
- create
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
apiVersion: rbac.authorization.k8s.io/v1
2+
kind: ClusterRoleBinding
3+
metadata:
4+
name: metrics-auth-rolebinding
5+
roleRef:
6+
apiGroup: rbac.authorization.k8s.io
7+
kind: ClusterRole
8+
name: metrics-auth-role
9+
subjects:
10+
- kind: ServiceAccount
11+
name: controller-manager
12+
namespace: system

0 commit comments

Comments
 (0)