From d764319fad063589326e640cf5dd3ccd2f0fc74f Mon Sep 17 00:00:00 2001 From: Stavros Kois <47820033+stavros-k@users.noreply.github.com> Date: Wed, 24 Aug 2022 18:11:49 +0300 Subject: [PATCH] chore(nextcloud): set overwrite.cli.url (#3541) Co-authored-by: Kjeld Schouten-Lebbing --- charts/stable/nextcloud/Chart.yaml | 2 +- charts/stable/nextcloud/templates/_hpb.tpl | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/charts/stable/nextcloud/Chart.yaml b/charts/stable/nextcloud/Chart.yaml index 6608a15aed9..3249e34266e 100644 --- a/charts/stable/nextcloud/Chart.yaml +++ b/charts/stable/nextcloud/Chart.yaml @@ -37,7 +37,7 @@ sources: - https://github.com/nextcloud/docker - https://github.com/nextcloud/helm type: application -version: 15.2.42 +version: 15.2.43 annotations: truecharts.org/catagories: | - cloud diff --git a/charts/stable/nextcloud/templates/_hpb.tpl b/charts/stable/nextcloud/templates/_hpb.tpl index b71b9e5768e..e318b956884 100644 --- a/charts/stable/nextcloud/templates/_hpb.tpl +++ b/charts/stable/nextcloud/templates/_hpb.tpl @@ -108,6 +108,15 @@ command: {{ if .Values.imaginary.preview_font }}php /var/www/html/occ config:system:set enabledPreviewProviders {{ $c }} --value='OC\Preview\Font'{{ $c = add1 $c }}{{ end }} {{- end }} + # Set overwrite.cli.uri + {{- $url := ( printf "http://%s/" ( .Values.env.AccessIP | default ( printf "%v-%v" .Release.Name "nextcloud" ) ) ) }} + {{- if .Values.ingress.main.enabled }} + {{- with (first .Values.ingress.main.hosts) }} + {{- $url = ( printf "https://%s/" .host ) }} + {{- end }} + {{- end }} + php /var/www/html/occ config:system:set overwrite.cli.url --value='{{ $url }}' + until $(curl --output /dev/null --silent --head --fail -H "Host: test.fakedomain.dns" http://127.0.0.1:7867/push/test/cookie); do echo "High Performance Backend not running ... waiting..." sleep 10