diff --git a/charts/fluent-bit/templates/_helpers.tpl b/charts/fluent-bit/templates/_helpers.tpl index f46f88d2..1e1b867e 100644 --- a/charts/fluent-bit/templates/_helpers.tpl +++ b/charts/fluent-bit/templates/_helpers.tpl @@ -52,9 +52,9 @@ app.kubernetes.io/instance: {{ .Release.Name }} {{- end -}} {{/* -Pod labels +Verbose Pod labels */}} -{{- define "fluent-bit.podLabels" -}} +{{- define "fluent-bit.verbosePodLabels" -}} {{ include "fluent-bit.selectorLabels" . }} {{- if .Chart.AppVersion }} app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} diff --git a/charts/fluent-bit/templates/daemonset.yaml b/charts/fluent-bit/templates/daemonset.yaml index 49feedcf..752b8399 100644 --- a/charts/fluent-bit/templates/daemonset.yaml +++ b/charts/fluent-bit/templates/daemonset.yaml @@ -27,7 +27,11 @@ spec: template: metadata: labels: - {{- include "fluent-bit.podLabels" . | nindent 8 }} + {{- if .Values.verbosePodLabels.enabled }} + {{- include "fluent-bit.verbosePodLabels" . | nindent 8 }} + {{- else }} + {{- include "fluent-bit.selectorLabels" . | nindent 8 }} + {{- end }} {{- with .Values.podLabels }} {{- toYaml . | nindent 8 }} {{- end }} diff --git a/charts/fluent-bit/templates/deployment.yaml b/charts/fluent-bit/templates/deployment.yaml index ab092975..990a5d7b 100644 --- a/charts/fluent-bit/templates/deployment.yaml +++ b/charts/fluent-bit/templates/deployment.yaml @@ -30,7 +30,11 @@ spec: template: metadata: labels: - {{- include "fluent-bit.podLabels" . | nindent 8 }} + {{- if .Values.verbosePodLabels.enabled }} + {{- include "fluent-bit.verbosePodLabels" . | nindent 8 }} + {{- else }} + {{- include "fluent-bit.selectorLabels" . | nindent 8 }} + {{- end }} {{- with .Values.podLabels }} {{- toYaml . | nindent 8 }} {{- end }} diff --git a/charts/fluent-bit/values.yaml b/charts/fluent-bit/values.yaml index df4e47f1..99a8fea0 100644 --- a/charts/fluent-bit/values.yaml +++ b/charts/fluent-bit/values.yaml @@ -302,6 +302,10 @@ podAnnotations: {} podLabels: {} +# adds app.kubernetes.io/version label to pods for istio required labels +verbosePodLabels: + enabled: false + ## How long (in seconds) a pods needs to be stable before progressing the deployment ## minReadySeconds: