aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/sdc/charts/sdc-cs/templates/pv.yaml
blob: 31230a9ed7dde3ae96a974359986a92c105d511e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}}
kind: PersistentVolume
apiVersion: v1
metadata:
  name: {{ include "common.fullname" . }}
  namespace: {{ include "common.namespace" . }}
  labels:
    app: {{ include "common.name" . }}
    chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}"
    release: "{{ .Release.Name }}"
    heritage: "{{ .Release.Service }}"
    name: {{ include "common.fullname" . }}
spec:
  capacity:
    storage: {{ .Values.persistence.size}}
  accessModes:
    - {{ .Values.persistence.accessMode }}
  persistentVolumeReclaimPolicy: {{ .Values.persistence.volumeReclaimPolicy }}
  hostPath:
    path: {{ .Values.global.persistence.mountPath | default .Values.persistence.mountPath }}/{{ .Release.Name }}/{{ .Values.persistence.mountSubPath }}
{{- end -}}