From 047521a6530e3d8b1b2fd19b3e6f86372f0788c8 Mon Sep 17 00:00:00 2001 From: Kevin Hannon Date: Fri, 6 Dec 2024 11:18:43 -0500 Subject: [PATCH] working kube-rbac-proxy --- .../components/rbac/auth_proxy_client_binding.yaml | 12 ++++++++++++ config/components/rbac/kustomization.yaml | 3 ++- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 config/components/rbac/auth_proxy_client_binding.yaml diff --git a/config/components/rbac/auth_proxy_client_binding.yaml b/config/components/rbac/auth_proxy_client_binding.yaml new file mode 100644 index 00000000..2d14de4d --- /dev/null +++ b/config/components/rbac/auth_proxy_client_binding.yaml @@ -0,0 +1,12 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: metrics-reader-rolebinding +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: metrics-reader +subjects: +- kind: ServiceAccount + name: controller-manager + namespace: system \ No newline at end of file diff --git a/config/components/rbac/kustomization.yaml b/config/components/rbac/kustomization.yaml index 334fe151..2c2fcccb 100644 --- a/config/components/rbac/kustomization.yaml +++ b/config/components/rbac/kustomization.yaml @@ -9,8 +9,9 @@ resources: - role_binding.yaml - leader_election_role.yaml - leader_election_role_binding.yaml -# Comment the following 3 lines if you want to disable +# Comment the following 4 lines if you want to disable # protecting your /metrics endpoint. - auth_proxy_role.yaml - auth_proxy_role_binding.yaml - auth_proxy_client_clusterrole.yaml +- auth_proxy_client_binding.yaml