From 6bde4c49aafe4e8a503c8b7ad18e46a3d8c19fec Mon Sep 17 00:00:00 2001 From: Arvind Iyengar Date: Fri, 10 Feb 2023 15:30:31 -0800 Subject: [PATCH] Remove faulty .Capabilities check for node-exporter --- .../patch/templates/psp-clusterrole.yaml.patch | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/packages/rancher-monitoring/rancher-node-exporter/generated-changes/patch/templates/psp-clusterrole.yaml.patch b/packages/rancher-monitoring/rancher-node-exporter/generated-changes/patch/templates/psp-clusterrole.yaml.patch index 800a95d38..772c2b14b 100644 --- a/packages/rancher-monitoring/rancher-node-exporter/generated-changes/patch/templates/psp-clusterrole.yaml.patch +++ b/packages/rancher-monitoring/rancher-node-exporter/generated-changes/patch/templates/psp-clusterrole.yaml.patch @@ -1,23 +1,9 @@ --- charts-original/templates/psp-clusterrole.yaml +++ charts/templates/psp-clusterrole.yaml -@@ -1,15 +1,17 @@ +@@ -1,5 +1,5 @@ {{- if .Values.rbac.create }} -{{- if .Values.rbac.pspEnabled }} +{{- if .Values.global.cattle.psp.enabled }} kind: ClusterRole apiVersion: rbac.authorization.k8s.io/v1 metadata: - name: psp-{{ template "prometheus-node-exporter.fullname" . }} - labels: {{ include "prometheus-node-exporter.labels" . | indent 4 }} - rules: -+{{- if .Capabilities.APIVersions.Has "policy/v1beta1/PodSecurityPolicies" }} - - apiGroups: ['extensions'] - resources: ['podsecuritypolicies'] - verbs: ['use'] - resourceNames: - - {{ template "prometheus-node-exporter.fullname" . }} -+{{- end }} - {{- end }} --{{- end }} -+{{- end }} -\ No newline at end of file