mirror of
https://github.com/truenas/charts.git
synced 2026-06-28 00:06:45 +08:00
NAS-124095 / 24.04 / add kapowarr to community train (#1537)
This commit is contained in:
1
library/ix-dev/community/kapowarr/templates/NOTES.txt
Normal file
1
library/ix-dev/community/kapowarr/templates/NOTES.txt
Normal file
@@ -0,0 +1 @@
|
||||
{{ include "ix.v1.common.lib.chart.notes" $ }}
|
||||
46
library/ix-dev/community/kapowarr/templates/_kapowarr.tpl
Normal file
46
library/ix-dev/community/kapowarr/templates/_kapowarr.tpl
Normal file
@@ -0,0 +1,46 @@
|
||||
{{- define "kapowarr.workload" -}}
|
||||
workload:
|
||||
kapowarr:
|
||||
enabled: true
|
||||
primary: true
|
||||
type: Deployment
|
||||
podSpec:
|
||||
hostNetwork: false
|
||||
containers:
|
||||
kapowarr:
|
||||
enabled: true
|
||||
primary: true
|
||||
imageSelector: image
|
||||
securityContext:
|
||||
runAsUser: {{ .Values.kapowarrRunAs.user }}
|
||||
runAsGroup: {{ .Values.kapowarrRunAs.group }}
|
||||
{{ with .Values.kapowarrConfig.additionalEnvs }}
|
||||
envList:
|
||||
{{ range $env := . }}
|
||||
- name: {{ $env.name }}
|
||||
value: {{ $env.value }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
probes:
|
||||
liveness:
|
||||
enabled: true
|
||||
type: http
|
||||
port: 5656
|
||||
path: /
|
||||
readiness:
|
||||
enabled: true
|
||||
type: http
|
||||
port: 5656
|
||||
path: /
|
||||
startup:
|
||||
enabled: true
|
||||
type: http
|
||||
port: 5656
|
||||
path: /
|
||||
initContainers:
|
||||
{{- include "ix.v1.common.app.permissions" (dict "containerName" "01-permissions"
|
||||
"UID" .Values.kapowarrRunAs.user
|
||||
"GID" .Values.kapowarrRunAs.group
|
||||
"mode" "check"
|
||||
"type" "init") | nindent 8 }}
|
||||
{{- end -}}
|
||||
49
library/ix-dev/community/kapowarr/templates/_persistence.tpl
Normal file
49
library/ix-dev/community/kapowarr/templates/_persistence.tpl
Normal file
@@ -0,0 +1,49 @@
|
||||
{{- define "kapowarr.persistence" -}}
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: {{ .Values.kapowarrStorage.config.type }}
|
||||
datasetName: {{ .Values.kapowarrStorage.config.datasetName | default "" }}
|
||||
hostPath: {{ .Values.kapowarrStorage.config.hostPath | default "" }}
|
||||
targetSelector:
|
||||
kapowarr:
|
||||
kapowarr:
|
||||
mountPath: /app/db
|
||||
01-permissions:
|
||||
mountPath: /mnt/directories/config
|
||||
downloads:
|
||||
enabled: true
|
||||
type: {{ .Values.kapowarrStorage.downloads.type }}
|
||||
datasetName: {{ .Values.kapowarrStorage.downloads.datasetName | default "" }}
|
||||
hostPath: {{ .Values.kapowarrStorage.downloads.hostPath | default "" }}
|
||||
targetSelector:
|
||||
kapowarr:
|
||||
kapowarr:
|
||||
mountPath: /app/temp_downloads
|
||||
01-permissions:
|
||||
mountPath: /mnt/directories/downloads
|
||||
content:
|
||||
enabled: true
|
||||
type: {{ .Values.kapowarrStorage.content.type }}
|
||||
datasetName: {{ .Values.kapowarrStorage.content.datasetName | default "" }}
|
||||
hostPath: {{ .Values.kapowarrStorage.content.hostPath | default "" }}
|
||||
targetSelector:
|
||||
kapowarr:
|
||||
kapowarr:
|
||||
mountPath: /content
|
||||
01-permissions:
|
||||
mountPath: /mnt/directories/content
|
||||
{{- range $idx, $storage := .Values.kapowarrStorage.additionalStorages }}
|
||||
{{ printf "kapowarr-%v" (int $idx) }}:
|
||||
enabled: true
|
||||
type: {{ $storage.type }}
|
||||
datasetName: {{ $storage.datasetName | default "" }}
|
||||
hostPath: {{ $storage.hostPath | default "" }}
|
||||
targetSelector:
|
||||
kapowarr:
|
||||
kapowarr:
|
||||
mountPath: {{ $storage.mountPath }}
|
||||
01-permissions:
|
||||
mountPath: /mnt/directories{{ $storage.mountPath }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
12
library/ix-dev/community/kapowarr/templates/_portal.tpl
Normal file
12
library/ix-dev/community/kapowarr/templates/_portal.tpl
Normal file
@@ -0,0 +1,12 @@
|
||||
{{- define "kapowarr.portal" -}}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: portal
|
||||
data:
|
||||
path: "/"
|
||||
port: {{ .Values.kapowarrNetwork.webPort | quote }}
|
||||
protocol: http
|
||||
host: $node_ip
|
||||
{{- end -}}
|
||||
16
library/ix-dev/community/kapowarr/templates/_service.tpl
Normal file
16
library/ix-dev/community/kapowarr/templates/_service.tpl
Normal file
@@ -0,0 +1,16 @@
|
||||
{{- define "kapowarr.service" -}}
|
||||
service:
|
||||
kapowarr:
|
||||
enabled: true
|
||||
primary: true
|
||||
type: NodePort
|
||||
targetSelector: kapowarr
|
||||
ports:
|
||||
webui:
|
||||
enabled: true
|
||||
primary: true
|
||||
port: {{ .Values.kapowarrNetwork.webPort }}
|
||||
nodePort: {{ .Values.kapowarrNetwork.webPort }}
|
||||
targetPort: 5656
|
||||
targetSelector: kapowarr
|
||||
{{- end -}}
|
||||
11
library/ix-dev/community/kapowarr/templates/common.yaml
Normal file
11
library/ix-dev/community/kapowarr/templates/common.yaml
Normal file
@@ -0,0 +1,11 @@
|
||||
{{- include "ix.v1.common.loader.init" . -}}
|
||||
|
||||
{{/* Merge the templates with Values */}}
|
||||
{{- $_ := mustMergeOverwrite .Values (include "kapowarr.workload" $ | fromYaml) -}}
|
||||
{{- $_ := mustMergeOverwrite .Values (include "kapowarr.service" $ | fromYaml) -}}
|
||||
{{- $_ := mustMergeOverwrite .Values (include "kapowarr.persistence" $ | fromYaml) -}}
|
||||
|
||||
{{/* Create the configmap for portal manually*/}}
|
||||
{{- include "kapowarr.portal" $ -}}
|
||||
|
||||
{{- include "ix.v1.common.loader.apply" . -}}
|
||||
Reference in New Issue
Block a user