prosody: fix cross-domain WS default value

Somehow the ENV directive doesn't work in all cases (?) and I got a
template error when upgrading.
pull/804/head
Saúl Ibarra Corretgé 4 years ago
parent 8261f7233c
commit c2c646054b
  1. 5
      prosody/rootfs/defaults/conf.d/jitsi-meet.cfg.lua

@ -31,11 +31,12 @@ consider_bosh_secure = true;
-- Deprecated in 0.12 -- Deprecated in 0.12
-- https://github.com/bjc/prosody/commit/26542811eafd9c708a130272d7b7de77b92712de -- https://github.com/bjc/prosody/commit/26542811eafd9c708a130272d7b7de77b92712de
{{ $XMPP_CROSS_DOMAINS := $PUBLIC_URL }} {{ $XMPP_CROSS_DOMAINS := $PUBLIC_URL }}
{{ if eq .Env.XMPP_CROSS_DOMAIN "true"}} {{ $XMPP_CROSS_DOMAIN := .Env.XMPP_CROSS_DOMAIN | default "" }}
{{ if eq $XMPP_CROSS_DOMAIN "true"}}
cross_domain_websocket = true cross_domain_websocket = true
cross_domain_bosh = true cross_domain_bosh = true
{{ else }} {{ else }}
{{ if and .Env.XMPP_CROSS_DOMAIN (not (eq .Env.XMPP_CROSS_DOMAIN "false" )) }} {{ if not (eq $XMPP_CROSS_DOMAIN "false") }}
{{ $XMPP_CROSS_DOMAINS = list $PUBLIC_URL .Env.XMPP_CROSS_DOMAIN | join "," }} {{ $XMPP_CROSS_DOMAINS = list $PUBLIC_URL .Env.XMPP_CROSS_DOMAIN | join "," }}
{{ end }} {{ end }}
cross_domain_websocket = { "{{ join "\",\"" (splitList "," $XMPP_CROSS_DOMAINS) }}" } cross_domain_websocket = { "{{ join "\",\"" (splitList "," $XMPP_CROSS_DOMAINS) }}" }

Loading…
Cancel
Save