Explorar o código

Only set OVERWRITEHOST if both host and port are defined (#1233)

Stavros Kois %!s(int64=2) %!d(string=hai) anos
pai
achega
fc86878729

+ 1 - 1
library/ix-dev/charts/nextcloud/Chart.yaml

@@ -4,7 +4,7 @@ description: A file sharing server that puts the control and security of your ow
 annotations:
   title: Nextcloud
 type: application
-version: 1.6.28
+version: 1.6.29
 apiVersion: v2
 appVersion: 26.0.2
 kubeVersion: '>=1.16.0-0'

+ 2 - 0
library/ix-dev/charts/nextcloud/templates/deployment.yaml

@@ -79,7 +79,9 @@ spec: {{ include "common.deployment.common_spec" . | nindent 2 }}
         {{ $envList = mustAppend $envList (dict "name" "NEXTCLOUD_DATA_DIR" "value" .Values.nextcloud.datadir) }}
         {{ if eq (include "nginx.certAvailable" .) "true" }}
         {{ $envList = mustAppend $envList (dict "name" "APACHE_DISABLE_REWRITE_IP" "value" "1") }}
+          {{ if and .Values.nextcloud.host .Values.service.nodePort }}
         {{ $envList = mustAppend $envList (dict "name" "OVERWRITEHOST" "value" (printf "%v:%v" .Values.nextcloud.host .Values.service.nodePort)) }}
+          {{ end }}
         {{ $envList = mustAppend $envList (dict "name" "OVERWRITEPROTOCOL" "value" "https") }}
         {{ $envList = mustAppend $envList (dict "name" "TRUSTED_PROXIES" "value" "127.0.0.1") }}
         {{ end }}