Fluentd: Add support for arbitrary environment vars

This updates the Fluentd deployment template to use the helm
toolkit util for generating environment variables through the
chart's values.yaml. This adds flexibility in defining fluentd
outputs, as arbitrary environment variables can be injected and
consumed in fluentd's filters and outputs

Change-Id: I72a2c476378cc555bde1387781b4a06f13b51bc6
Signed-off-by: Steve Wilkerson <sw5822@att.com>
This commit is contained in:
Steve Wilkerson 2019-09-04 09:48:19 -05:00
parent 43c89812c5
commit 5b14b6c162
2 changed files with 5 additions and 0 deletions

View File

@ -161,6 +161,9 @@ spec:
value: {{ tuple "elasticsearch" "internal" "http" . | include "helm-toolkit.endpoints.endpoint_port_lookup" | quote }}
- name: KAFKA_BROKER
value: {{ $kafkaBrokerURI }}
{{- if .Values.pod.env.fluentd }}
{{ include "helm-toolkit.utils.to_k8s_env_vars" .Values.pod.env.fluentd | indent 12 }}
{{- end }}
- name: ELASTICSEARCH_USERNAME
valueFrom:
secretKeyRef:

View File

@ -405,6 +405,8 @@ network_policy:
- {}
pod:
env:
fluentd: null
tolerations:
fluentd:
enabled: false