{{- if .Values.graphinsights.enabled }}
{{- if .Values.graphinsights.persistence.enabled }}
{{- if not .Values.graphinsights.persistence.existentPvc.enabled }}
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: {{ template "cmem.name-graphinsights" . }}-data
  namespace: {{ .Release.Namespace }}
  labels:
    {{- include "cmem.labels-graphinsights" . | nindent 4 }}
spec:
  storageClassName: {{ .Values.graphinsights.persistence.storageClassName }}
  resources:
    {{- toYaml .Values.graphinsights.persistence.resources | nindent 4 }}
  accessModes:
    - ReadWriteOnce
{{- end }}
{{- end }}
{{- end }}
