feat(plex): Pre-fill ADVERTISE_IP with the server ip and ingress (#3464)

* feat(plex): Pre-fill ADVERTISE_IP with the server ip

* slight change

* update values

* remove

* url with port

* update description

* move non-env values to another dict

* fix reference
This commit is contained in:
Stavros Kois
2022-08-18 22:12:25 +02:00
committed by GitHub
parent 933a774d06
commit 741f0425fe
3 changed files with 34 additions and 9 deletions
+11 -1
View File
@@ -7,6 +7,7 @@ service:
main:
ports:
main:
protocol: HTTP
port: 32400
targetPort: 32400
@@ -15,9 +16,18 @@ persistence:
enabled: true
mountPath: "/config"
plex:
serverURL: "{{ .Values.service.main.ports.main.protocol | lower }}://{{ .Values.plex.serverIP }}:{{ .Values.service.main.ports.main.port }}"
serverIngressURL: "{{ if .Values.ingress.main.enabled }}{{ with (first .Values.ingress.main.hosts) }},https://{{ .host }}{{ end }}{{ end }}"
serverIngressURLPort: "{{ if .Values.ingress.main.enabled }}{{ with (first .Values.ingress.main.hosts) }},https://{{ .host }}:{{ .Values.service.main.ports.main.port }}{{ end }}{{ end }}"
# User Defined
serverIP: "127.0.0.1"
additionalAdvertiseURL: ""
env:
ADVERTISE_IP: "{{ tpl (.Values.plex.serverURL) .}}{{ tpl (.Values.plex.serverIngressURL) . }}{{ tpl (.Values.plex.serverIngressURLPort) . }}{{ with .Values.plex.additionalAdvertiseURL }},{{ . }}{{ end }}"
# User Defined
ALLOWED_NETWORKS: "172.16.0.0/12,10.0.0.0/8,192.168.0.0/16"
ADVERTISE_IP: ""
PLEX_CLAIM: ""
portal: