scale-catalog/stable/transmission/19.2.0/templates/common.yaml
Julian Haseleu 5d1ab94342 cleanup
2024-07-14 21:54:53 +00:00

16 lines
1018 B
YAML

{{/* Make sure all variables are set properly */}}
{{- include "tc.v1.common.loader.init" . }}
{{/* Set it to the same port as "torrent" service/port */}}
{{- $_ := set $.Values.service.torrent.ports.torrentudp "port" .Values.service.torrent.ports.torrent.port -}}
{{- if .Values.workload.main.podSpec.containers.main.env.TRANSMISSION_RPC_AUTHENTICATION_REQUIRED -}}
{{- $headers := (dict "Authorization" (printf "Basic %s" (printf "%s:%s" .Values.workload.main.podSpec.containers.main.env.TRANSMISSION_RPC_USERNAME .Values.workload.main.podSpec.containers.main.env.TRANSMISSION_RPC_PASSWORD | b64enc))) -}}
{{- $_ := set $.Values.workload.main.podSpec.containers.main.probes.liveness "httpHeaders" $headers -}}
{{- $_ := set $.Values.workload.main.podSpec.containers.main.probes.readiness "httpHeaders" $headers -}}
{{- $_ := set $.Values.workload.main.podSpec.containers.main.probes.startup "httpHeaders" $headers -}}
{{- end -}}
{{/* Render the templates */}}
{{ include "tc.v1.common.loader.apply" . }}