Files
chart/library/ix-dev/community/tdarr/templates/_tdarr.tpl
Stavros Kois df4b8ae4ac Adds smb-pv-pvc option to apps (#1670)
* autobrr

* bazarr

* briefkasten

* castopod

* cloudflared

* deluge

* distribution

* drawio

* filebrowser

* flame

* frigaet

* fscrawler

* grafana

* bump missed app

* homarr

* homepage

* homer

* jellyfin

* jenkins

* kapowarr

* kavita

* komga

* lidarr

* linkding

* listmonk

* logseq

* metube

* minecraft

* n8n

* navidrome

* node-red

* omada

* paperless

* passbolt

* pgadmin

* pigallery

* piwigo

* planka

* plex auto lang

* prowlarr

* qbit

* radarr

* readarr

* recyclarr

* rust-desk

* sabnzbd

* searxng

* sftpgo

* sonarr

* tautulli

* tdarr

* tmm

* transmission

* 2fauth

* unifi

* unifi backup

* whoogle

* wordpress

* syncthing-enterprise

* immutable type
2023-10-26 18:08:46 +03:00

158 lines
4.6 KiB
Smarty

{{- define "tdarr.workload" -}}
workload:
tdarr:
enabled: true
primary: true
type: Deployment
podSpec:
hostNetwork: false
securityContext:
fsGroup: {{ .Values.tdarrID.group }}
containers:
tdarr:
enabled: true
primary: true
imageSelector: image
securityContext:
runAsUser: 0
runAsGroup: 0
readOnlyRootFilesystem: false
runAsNonRoot: false
capabilities:
add:
- CHOWN
- FOWNER
- SETUID
- SETGID
env:
inContainer: "true"
internalNode: {{ .Values.tdarrConfig.internalNode | quote }}
serverPort: {{ .Values.tdarrNetwork.serverPort }}
webUIPort: {{ .Values.tdarrNetwork.webPort }}
nodeName: {{ .Values.tdarrConfig.nodeName }}
serverIP: {{ .Values.tdarrConfig.serverIP }}
fixedEnv:
PUID: {{ .Values.tdarrID.user }}
{{ with .Values.tdarrConfig.additionalEnvs }}
envList:
{{ range $env := . }}
- name: {{ $env.name }}
value: {{ $env.value }}
{{ end }}
{{ end }}
probes:
liveness:
enabled: true
type: http
port: "{{ .Values.tdarrNetwork.webPort }}"
path: /api/v2/status
readiness:
enabled: true
type: http
port: "{{ .Values.tdarrNetwork.webPort }}"
path: /api/v2/status
startup:
enabled: true
type: http
port: "{{ .Values.tdarrNetwork.webPort }}"
path: /api/v2/status
{{/* Service */}}
service:
tdarr:
enabled: true
primary: true
type: NodePort
targetSelector: tdarr
ports:
webui:
enabled: true
primary: true
port: {{ .Values.tdarrNetwork.webPort }}
nodePort: {{ .Values.tdarrNetwork.webPort }}
targetSelector: tdarr
server:
enabled: true
port: {{ .Values.tdarrNetwork.serverPort }}
nodePort: {{ .Values.tdarrNetwork.serverPort }}
targetSelector: tdarr
{{/* Persistence */}}
persistence:
server:
enabled: true
type: {{ .Values.tdarrStorage.server.type }}
datasetName: {{ .Values.tdarrStorage.server.datasetName | default "" }}
hostPath: {{ .Values.tdarrStorage.server.hostPath | default "" }}
targetSelector:
tdarr:
tdarr:
mountPath: /app/server
configs:
enabled: true
type: {{ .Values.tdarrStorage.configs.type }}
datasetName: {{ .Values.tdarrStorage.configs.datasetName | default "" }}
hostPath: {{ .Values.tdarrStorage.configs.hostPath | default "" }}
targetSelector:
tdarr:
tdarr:
mountPath: /app/configs
logs:
enabled: true
type: {{ .Values.tdarrStorage.logs.type }}
datasetName: {{ .Values.tdarrStorage.logs.datasetName | default "" }}
hostPath: {{ .Values.tdarrStorage.logs.hostPath | default "" }}
targetSelector:
tdarr:
tdarr:
mountPath: /app/logs
transcode:
enabled: true
type: {{ .Values.tdarrStorage.transcodes.type }}
datasetName: {{ .Values.tdarrStorage.transcodes.datasetName | default "" }}
hostPath: {{ .Values.tdarrStorage.transcodes.hostPath | default "" }}
medium: {{ .Values.tdarrStorage.transcodes.medium | default "" }}
{{/* Size of the emptyDir */}}
size: {{ .Values.tdarrStorage.transcodes.size | default "" }}
targetSelector:
tdarr:
tdarr:
mountPath: /temp
{{- range $idx, $storage := .Values.tdarrStorage.additionalStorages }}
{{ printf "tdarr-%v" (int $idx) }}:
{{- $size := "" -}}
{{- if $storage.size -}}
{{- $size = (printf "%vGi" $storage.size) -}}
{{- end }}
enabled: true
type: {{ $storage.type }}
datasetName: {{ $storage.datasetName | default "" }}
hostPath: {{ $storage.hostPath | default "" }}
server: {{ $storage.server | default "" }}
share: {{ $storage.share | default "" }}
domain: {{ $storage.domain | default "" }}
username: {{ $storage.username | default "" }}
password: {{ $storage.password | default "" }}
size: {{ $size }}
{{- if eq $storage.type "smb-pv-pvc" }}
mountOptions:
- key: noperm
{{- end }}
targetSelector:
tdarr:
tdarr:
mountPath: {{ $storage.mountPath }}
{{- end }}
{{ with .Values.tdarrGPU }}
scaleGPU:
{{ range $key, $value := . }}
- gpu:
{{ $key }}: {{ $value }}
targetSelector:
tdarr:
- tdarr
{{ end }}
{{ end }}
{{- end -}}