apiVersion: apps/v1 kind: Deployment metadata: name: {{ include "jellyfin.fullname" . }} labels: {{- include "jellyfin.labels" . | nindent 4 }} spec: {{- if not .Values.autoscaling.enabled }} replicas: {{ .Values.replicaCount }} {{- end }} selector: matchLabels: {{- include "jellyfin.selectorLabels" . | nindent 6 }} template: metadata: {{- with .Values.podAnnotations }} annotations: {{- toYaml . | nindent 8 }} {{- end }} labels: {{- include "jellyfin.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: - name: {{ .Chart.Name }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} resources: {{- toYaml .Values.resources | nindent 12 }} volumeMounts: - mountPath: /media name: jf-media readOnly: True - mountPath: /config name: jf-config - mountPath: /cache name: jf-cache - mountPath: /media-longhorn/tv-1 name: jf-longhorn-tv-1 - mountPath: /media-longhorn/tv-2 name: jf-longhorn-tv-2 - mountPath: /media-longhorn/tv-3 name: jf-longhorn-tv-3 tolerations: - key: face operator: Equal value: bad effect: NoSchedule volumes: - name: jf-media persistentVolumeClaim: claimName: jf-media-pvc - name: jf-config persistentVolumeClaim: claimName: jf-config-pvc - name: jf-cache persistentVolumeClaim: claimName: jf-cache-pvc - name: jf-longhorn-tv-1 persistentVolumeClaim: claimName: jf-longhorn-tv-1 - name: jf-longhorn-tv-2 persistentVolumeClaim: claimName: jf-longhorn-tv-2 - name: jf-longhorn-tv-3 persistentVolumeClaim: claimName: jf-longhorn-tv-3 {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }}