diff options
author | 2020-01-23 11:45:43 +0100 | |
---|---|---|
committer | 2020-01-23 12:00:58 +0100 | |
commit | b20067e569ff2ee59b59170089ba1b1efd322acb (patch) | |
tree | 9b9a7d5b74899c3f53cc616278f3ca3528473ec4 /kubernetes/common/postgres/templates/pvc-primary.yaml | |
parent | 70fc0f2694d1353ea93437fc49415598f147d0ca (diff) |
[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 <sylvain.desbureaux@orange.com>
Change-Id: I3c42b28ad5bea67eda004b0209c8a21783b539f1
Diffstat (limited to 'kubernetes/common/postgres/templates/pvc-primary.yaml')
-rw-r--r-- | kubernetes/common/postgres/templates/pvc-primary.yaml | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kubernetes/common/postgres/templates/pvc-primary.yaml b/kubernetes/common/postgres/templates/pvc-primary.yaml index 05a5088966..e529da1bd5 100644 --- a/kubernetes/common/postgres/templates/pvc-primary.yaml +++ b/kubernetes/common/postgres/templates/pvc-primary.yaml @@ -36,5 +36,10 @@ spec: resources: requests: storage: {{ .Values.persistence.size }} +{{- if include "common.needPV" . }} + storageClassName: "{{ include "common.fullname" . }}-primary" +{{- else }} + storageClassName: {{ include "common.storageClass" . }} +{{- end }} storageClassName: "{{ include "common.fullname" . }}-primary" {{- end -}} |