[COMMON] Fix PV/PVC for postgres
[oom.git] / kubernetes / common / postgres / templates / pv-primary.yaml
index 096f0c9..1764868 100644 (file)
@@ -14,6 +14,7 @@
 # # limitations under the License.
 */}}
 {{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}}
+{{- if include "common.needPV" . -}}
 kind: PersistentVolume
 apiVersion: v1
 metadata:
@@ -35,3 +36,4 @@ spec:
   hostPath:
     path: {{ .Values.global.persistence.mountPath | default .Values.persistence.mountPath }}/{{ .Release.Name }}/{{ .Values.persistence.mountSubPath }}/primary
 {{- end -}}
+{{- end -}}