make charts

pull/2410/head
Arvind Iyengar 2023-02-10 15:12:21 -08:00
parent 1cf7b1a468
commit ac311947a5
No known key found for this signature in database
GPG Key ID: A8DD9BFD6C811498
6 changed files with 5 additions and 11 deletions

View File

@ -8,16 +8,12 @@ metadata:
rules:
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
{{- if semverCompare "> 1.15.0-0" $kubeTargetVersion }}
{{- if .Capabilities.APIVersions.Has "policy/v1beta1/PodSecurityPolicies" }}
- apiGroups: ['policy']
{{- end }}
{{- else }}
- apiGroups: ['extensions']
{{- end }}
{{- if .Capabilities.APIVersions.Has "policy/v1beta1/PodSecurityPolicies" }}
resources: ['podsecuritypolicies']
verbs: ['use']
resourceNames:
- {{ template "kube-state-metrics.fullname" . }}
{{- end }}
{{- end }}

View File

@ -10,6 +10,6 @@
echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ template "prometheus-node-exporter.namespace" . }} -l "app.kubernetes.io/name={{ template "prometheus-node-exporter.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
echo "Visit http://127.0.0.1:9100 to use your application"
kubectl port-forward --namespace {{ template "prometheus-node-exporter.namespace" . }} $POD_NAME 9100
echo "Visit http://127.0.0.1:{{ .Values.service.port }} to use your application"
kubectl port-forward --namespace {{ template "prometheus-node-exporter.namespace" . }} $POD_NAME {{ .Values.service.port }}
{{- end }}

View File

@ -12,6 +12,6 @@ subsets:
{{- end }}
ports:
- name: {{ .Values.service.portName }}
port: 9100
port: {{ .Values.service.port }}
protocol: TCP
{{- end }}

View File

@ -6,7 +6,6 @@ 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']
@ -14,4 +13,3 @@ rules:
- {{ template "prometheus-node-exporter.fullname" . }}
{{- end }}
{{- end }}
{{- end }}

View File

@ -8470,7 +8470,7 @@ entries:
catalog.cattle.io/upstream-version: 19.0.3
apiVersion: v2
appVersion: 0.59.1
created: "2023-02-09T12:09:18.068738-08:00"
created: "2023-02-10T15:33:23.729015-08:00"
dependencies:
- condition: grafana.enabled
name: grafana
@ -8541,7 +8541,7 @@ entries:
description: Collects several related Helm charts, Grafana dashboards, and Prometheus
rules combined with documentation and scripts to provide easy to operate end-to-end
Kubernetes cluster monitoring with Prometheus using the Prometheus Operator.
digest: 3907fb8dd90fd0f17b116ab7acd8580a3602ea17ac34550127c6b6afab45dfd8
digest: 655e8fe1f29979950dfe1900ad3ee2a3392dc7235e54d90e4fff79bb4e2e56b2
home: https://github.com/prometheus-operator/kube-prometheus
icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/assets/prometheus_logo-cb55bb5c346.png
keywords: