From b20067e569ff2ee59b59170089ba1b1efd322acb Mon Sep 17 00:00:00 2001 From: Sylvain Desbureaux Date: Thu, 23 Jan 2020 11:45:43 +0100 Subject: [COMMON] Fix PV/PVC for postgres When creating https://gerrit.onap.org/r/c/oom/+/99478, forgot to backport storage class part of https://gerrit.onap.org/r/c/oom/+/98962. Issue-ID: OOM-2234 Issue-ID: OOM-1227 Signed-off-by: Sylvain Desbureaux Change-Id: I3c42b28ad5bea67eda004b0209c8a21783b539f1 --- kubernetes/common/postgres/templates/pvc-replica.yaml | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'kubernetes/common/postgres/templates/pvc-replica.yaml') diff --git a/kubernetes/common/postgres/templates/pvc-replica.yaml b/kubernetes/common/postgres/templates/pvc-replica.yaml index f740521919..41199b6861 100644 --- a/kubernetes/common/postgres/templates/pvc-replica.yaml +++ b/kubernetes/common/postgres/templates/pvc-replica.yaml @@ -36,5 +36,9 @@ spec: resources: requests: storage: {{ .Values.persistence.size }} +{{- if include "common.needPV" . }} storageClassName: "{{ include "common.fullname" . }}-replica" +{{- else }} + storageClassName: {{ include "common.storageClass" . }} +{{- end }} {{- end -}} -- cgit 1.2.3-korg