Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update PVC mount point #9

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/frigate/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
appVersion: "0.8.0"
description: NVR With Realtime Object Detection for IP Cameras
name: frigate
version: 6.0.1
version: 7.0.0
keywords:
- tensorflow
- coral
Expand Down
28 changes: 0 additions & 28 deletions charts/frigate/templates/data-pvc.yaml

This file was deleted.

10 changes: 5 additions & 5 deletions charts/frigate/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ spec:
{{- end }}
- mountPath: /config
name: config
- mountPath: /data
name: data
- mountPath: /media
name: media
- name: dshm
mountPath: /dev/shm
{{- if .Values.extraVolumeMounts }}{{ toYaml .Values.extraVolumeMounts | trim | nindent 12 }}{{ end }}
Expand All @@ -105,10 +105,10 @@ spec:
hostPath:
path: {{ .Values.coral.hostPath }}
{{- end }}
- name: data
{{- if .Values.persistence.data.enabled }}
- name: media
{{- if .Values.persistence.media.enabled }}
persistentVolumeClaim:
claimName: {{ if .Values.persistence.data.existingClaim }}{{ .Values.persistence.data.existingClaim }}{{- else }}{{ template "frigate.fullname" . }}-data{{- end }}
claimName: {{ if .Values.persistence.media.existingClaim }}{{ .Values.persistence.media.existingClaim }}{{- else }}{{ template "frigate.fullname" . }}-media{{- end }}
{{- else }}
emptyDir: {}
{{- end }}
Expand Down
28 changes: 28 additions & 0 deletions charts/frigate/templates/media-pvc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if and .Values.persistence.media.enabled (not .Values.persistence.media.existingClaim) }}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: {{ template "frigate.fullname" . }}-media
{{- if .Values.persistence.media.skipuninstall }}
annotations:
"helm.sh/resource-policy": keep
{{- end }}
labels:
app.kubernetes.io/name: {{ include "frigate.name" . }}
helm.sh/chart: {{ include "frigate.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
spec:
accessModes:
- {{ .Values.persistence.media.accessMode | quote }}
resources:
requests:
storage: {{ .Values.persistence.media.size | quote }}
{{- if .Values.persistence.media.storageClass }}
{{- if (eq "-" .Values.persistence.media.storageClass) }}
storageClassName: ""
{{- else }}
storageClassName: "{{ .Values.persistence.media.storageClass }}"
{{- end }}
{{- end }}
{{- end -}}
2 changes: 1 addition & 1 deletion charts/frigate/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ ingress:
# - chart-example.local

persistence:
data:
media:
enabled: false
## frigate configuration data Persistent Volume Storage Class
## If defined, storageClassName: <storageClass>
Expand Down