From 989e47ae6dbb0f73e5491b4bc9398e50d34fe1a1 Mon Sep 17 00:00:00 2001 From: Sharon Vendrov Date: Thu, 22 Aug 2019 11:26:32 +0300 Subject: [PATCH] [stable/fluentd] fix wrong indentation caused to emptyDir usage instead of pvc (#16529) * fix wrong indentation caused to emptyDir usage Signed-off-by: Sharon * bump chart version Signed-off-by: Sharon --- stable/fluentd/Chart.yaml | 2 +- stable/fluentd/templates/deployment.yaml | 32 +++++++++++++----------- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/stable/fluentd/Chart.yaml b/stable/fluentd/Chart.yaml index 3c005d0990..3baf0847d9 100644 --- a/stable/fluentd/Chart.yaml +++ b/stable/fluentd/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 description: A Fluentd Elasticsearch Helm chart for Kubernetes. icon: https://raw.githubusercontent.com/fluent/fluentd-docs/master/public/logo/Fluentd_square.png name: fluentd -version: 2.0.0 +version: 2.0.1 appVersion: v2.4.0 home: https://www.fluentd.org/ sources: diff --git a/stable/fluentd/templates/deployment.yaml b/stable/fluentd/templates/deployment.yaml index 7e00981de8..c9500a07c9 100644 --- a/stable/fluentd/templates/deployment.yaml +++ b/stable/fluentd/templates/deployment.yaml @@ -97,23 +97,14 @@ spec: - name: config-volume-{{ template "fluentd.fullname" . }} configMap: name: {{ template "fluentd.fullname" . }} - - name: buffer - {{- if and .Values.persistence.enabled (not .Values.autoscaling.enabled) }} + {{- if and .Values.persistence.enabled (not .Values.autoscaling.enabled) }} + - name: buffer persistentVolumeClaim: - claimName: {{ template "fluentd.fullname" . }} - {{- else if and .Values.persistence.enabled (.Values.autoscaling.enabled) }} - volumeClaimTemplates: - - metadata: - name: buffer - spec: - accessModes: [{{ .Values.persistence.accessMode | quote }}] - storageClassName: {{ .Values.persistence.storageClass }} - resources: - requests: - storage: {{ .Values.persistence.size }} - {{- else }} + claimName: {{ template "fluentd.fullname" . }} + {{- else if (not .Values.persistence.enabled) }} + - name: buffer emptyDir: {} - {{- end }} + {{- end }} {{- with .Values.nodeSelector }} nodeSelector: {{ toYaml . | indent 8 }} @@ -126,3 +117,14 @@ spec: tolerations: {{ toYaml . | indent 8 }} {{- end }} +{{- if and .Values.persistence.enabled (.Values.autoscaling.enabled) }} + volumeClaimTemplates: + - metadata: + name: buffer + spec: + accessModes: [{{ .Values.persistence.accessMode }}] + storageClassName: {{ .Values.persistence.storageClass }} + resources: + requests: + storage: {{ .Values.persistence.size }} +{{- end }}