From 335c545385231110dedc0988145c1716cd803ddb Mon Sep 17 00:00:00 2001 From: Kjeld Schouten-Lebbing Date: Mon, 26 Sep 2022 12:12:10 +0200 Subject: [PATCH] Update _webui.tpl Signed-off-by: Kjeld Schouten-Lebbing --- charts/enterprise/blocky/templates/_webui.tpl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/charts/enterprise/blocky/templates/_webui.tpl b/charts/enterprise/blocky/templates/_webui.tpl index 422b8be225f..b83160401e8 100644 --- a/charts/enterprise/blocky/templates/_webui.tpl +++ b/charts/enterprise/blocky/templates/_webui.tpl @@ -36,6 +36,13 @@ startupProbe: env: - name: NODE_ENV value: "production" +{{- if .Values.ingress.main.enabled }} + {{- with (first .Values.ingress.main.hosts) }} + {{- $url = ( printf "https://%s" .host ) }} + {{- end }} +{{- else }} +{{- $url = .Values.webUI.apiURL }} +{{- end }} - name: API_URL - value: "{{ .Values.webUI.apiURL }}" + value: "{{ $url }}" {{- end -}}