Make charts

pull/1374/head
Brenda Rearden 2021-07-28 17:06:23 -07:00
parent 76e6f9e49f
commit 1c7fa8de6f
5 changed files with 22 additions and 2 deletions

View File

@ -50,8 +50,15 @@ app.kubernetes.io/part-of: "kiali"
Selector labels
*/}}
{{- define "kiali-server.selectorLabels" -}}
{{- $releaseName := .Release.Name -}}
{{- $fullName := include "kiali-server.fullname" . -}}
{{- $deployment := (lookup "apps/v1" "Deployment" .Release.Namespace $fullName) -}}
app.kubernetes.io/name: kiali
app.kubernetes.io/instance: {{ include "kiali-server.fullname" . }}
{{- if (and .Release.IsUpgrade $deployment)}}
app.kubernetes.io/instance: {{ (get (($deployment).metadata.labels) "app.kubernetes.io/instance") | default $fullName }}
{{- else }}
app.kubernetes.io/instance: {{ $fullName }}
{{- end }}
{{- end }}
{{/*

View File

@ -40,6 +40,12 @@ rules:
- '*'
verbs:
- '*'
- apiGroups:
- telemetry.istio.io
resources:
- '*'
verbs:
- '*'
# k8s groups
- apiGroups:
- admissionregistration.k8s.io

View File

@ -50,8 +50,15 @@ app.kubernetes.io/part-of: "kiali"
Selector labels
*/}}
{{- define "kiali-server.selectorLabels" -}}
{{- $releaseName := .Release.Name -}}
{{- $fullName := include "kiali-server.fullname" . -}}
{{- $deployment := (lookup "apps/v1" "Deployment" .Release.Namespace $fullName) -}}
app.kubernetes.io/name: kiali
app.kubernetes.io/instance: {{ include "kiali-server.fullname" . }}
{{- if (and .Release.IsUpgrade $deployment)}}
app.kubernetes.io/instance: {{ (get (($deployment).metadata.labels) "app.kubernetes.io/instance") | default $fullName }}
{{- else }}
app.kubernetes.io/instance: {{ $fullName }}
{{- end }}
{{- end }}
{{/*