{{- if and .Values.controller.enabled .Values.controller.pvc.enabled -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: neuvector-data
  namespace: {{ .Release.Namespace }}
  labels:
    chart: {{ template "neuvector.chart" . }}
    release: {{ .Release.Name }}
    heritage: {{ .Release.Service }}
spec:
  accessModes:
    - ReadWriteMany
  volumeMode: Filesystem
{{- if .Values.controller.pvc.storageClass }}
  storageClassName: {{ .Values.controller.pvc.storageClass }}
{{- end }}
  resources:
    requests:
      storage: 1Gi
{{- end }}