updating helm/docker files and database config files
[it/otf.git] / otf-helm / otf / charts / databases / mongodb / templates / pvc-standalone.yaml
diff --git a/otf-helm/otf/charts/databases/mongodb/templates/pvc-standalone.yaml b/otf-helm/otf/charts/databases/mongodb/templates/pvc-standalone.yaml
new file mode 100644 (file)
index 0000000..d37e897
--- /dev/null
@@ -0,0 +1,21 @@
+{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) (not .Values.replicaSet.enabled) (not .Values.useStatefulSet) }}
+kind: PersistentVolumeClaim
+apiVersion: v1
+metadata:
+  labels:
+    app: {{ template "mongodb.name" . }}
+    chart: {{ template "mongodb.chart" . }}
+    heritage: {{ .Release.Service }}
+    release: {{ .Release.Name }}
+  name: {{ template "mongodb.fullname" . }}
+  namespace: {{.Values.namespace }}
+spec:
+  accessModes:
+  {{- range .Values.persistence.accessModes }}
+    - {{ . | quote }}
+  {{- end }}
+  resources:
+    requests:
+      storage: {{ .Values.persistence.size | quote }}
+  {{ include "mongodb.storageClass" . }}
+{{- end }}