config: simplify configuration
Use default values everywhere so they don't need to be specified in the .env file. This makes the default .env file much smaller (the larger config options are documented in the handbook) and should make it easier to port the setup to runtimes other than Docker Compose.
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
{{ $ENABLE_COLIBRI_WEBSOCKET := .Env.ENABLE_COLIBRI_WEBSOCKET | default "1" | toBool }}
|
||||
{{ $ENABLE_XMPP_WEBSOCKET := .Env.ENABLE_XMPP_WEBSOCKET | default "1" | toBool }}
|
||||
{{ $ENABLE_SUBDOMAINS := .Env.ENABLE_SUBDOMAINS | default "true" | toBool -}}
|
||||
{{ $XMPP_DOMAIN := .Env.XMPP_DOMAIN | default "meet.jitsi" -}}
|
||||
{{ $XMPP_BOSH_URL_BASE := .Env.XMPP_BOSH_URL_BASE | default "http://xmpp.meet.jitsi:5280" -}}
|
||||
|
||||
server_name _;
|
||||
|
||||
@@ -64,21 +66,21 @@ location ~ ^/colibri-ws/([a-zA-Z0-9-\.]+)/(.*) {
|
||||
|
||||
# BOSH
|
||||
location = /http-bind {
|
||||
proxy_pass {{ .Env.XMPP_BOSH_URL_BASE }}/http-bind;
|
||||
proxy_pass {{ $XMPP_BOSH_URL_BASE }}/http-bind;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
proxy_set_header Host {{ .Env.XMPP_DOMAIN }};
|
||||
proxy_set_header Host {{ $XMPP_DOMAIN }};
|
||||
}
|
||||
|
||||
{{ if $ENABLE_XMPP_WEBSOCKET }}
|
||||
# xmpp websockets
|
||||
location = /xmpp-websocket {
|
||||
proxy_pass {{ .Env.XMPP_BOSH_URL_BASE }}/xmpp-websocket;
|
||||
proxy_pass {{ $XMPP_BOSH_URL_BASE }}/xmpp-websocket;
|
||||
proxy_http_version 1.1;
|
||||
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
|
||||
proxy_set_header Host {{ .Env.XMPP_DOMAIN }};
|
||||
proxy_set_header Host {{ $XMPP_DOMAIN }};
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
tcp_nodelay on;
|
||||
}
|
||||
|
||||
@@ -37,8 +37,8 @@
|
||||
{{ $DESKTOP_SHARING_FRAMERATE_MAX := .Env.DESKTOP_SHARING_FRAMERATE_MAX | default 5 -}}
|
||||
{{ $TESTING_OCTO_PROBABILITY := .Env.TESTING_OCTO_PROBABILITY | default "0" -}}
|
||||
{{ $TESTING_CAP_SCREENSHARE_BITRATE := .Env.TESTING_CAP_SCREENSHARE_BITRATE | default "1" -}}
|
||||
{{ $XMPP_DOMAIN := .Env.XMPP_DOMAIN -}}
|
||||
{{ $XMPP_RECORDER_DOMAIN := .Env.XMPP_RECORDER_DOMAIN -}}
|
||||
{{ $XMPP_DOMAIN := .Env.XMPP_DOMAIN | default "meet.jitsi" -}}
|
||||
{{ $XMPP_RECORDER_DOMAIN := .Env.XMPP_RECORDER_DOMAIN | default "recorder.meet.jitsi" -}}
|
||||
{{ $DISABLE_DEEP_LINKING := .Env.DISABLE_DEEP_LINKING | default "false" | toBool -}}
|
||||
{{ $VIDEOQUALITY_ENFORCE_PREFERRED_CODEC := .Env.VIDEOQUALITY_ENFORCE_PREFERRED_CODEC | default "false" | toBool -}}
|
||||
{{ $DISABLE_POLLS := .Env.DISABLE_POLLS | default "false" | toBool -}}
|
||||
|
||||
@@ -3,12 +3,13 @@
|
||||
{{ $ENABLE_GUESTS := .Env.ENABLE_GUESTS | default "false" | toBool -}}
|
||||
{{ $ENABLE_SUBDOMAINS := .Env.ENABLE_SUBDOMAINS | default "true" | toBool -}}
|
||||
{{ $ENABLE_XMPP_WEBSOCKET := .Env.ENABLE_XMPP_WEBSOCKET | default "1" | toBool -}}
|
||||
{{ $JICOFO_AUTH_USER := .Env.JICOFO_AUTH_USER | default "focus" }}
|
||||
{{ $JICOFO_AUTH_USER := .Env.JICOFO_AUTH_USER | default "focus" -}}
|
||||
{{ $PUBLIC_URL_DOMAIN := .Env.PUBLIC_URL | default "https://localhost:8443" | trimPrefix "https://" | trimSuffix "/" -}}
|
||||
{{ $XMPP_AUTH_DOMAIN := .Env.XMPP_AUTH_DOMAIN -}}
|
||||
{{ $XMPP_DOMAIN := .Env.XMPP_DOMAIN -}}
|
||||
{{ $XMPP_MUC_DOMAIN := .Env.XMPP_MUC_DOMAIN -}}
|
||||
{{ $XMPP_MUC_DOMAIN_PREFIX := (split "." .Env.XMPP_MUC_DOMAIN)._0 -}}
|
||||
{{ $XMPP_AUTH_DOMAIN := .Env.XMPP_AUTH_DOMAIN | default "auth.meet.jitsi" -}}
|
||||
{{ $XMPP_DOMAIN := .Env.XMPP_DOMAIN | default "meet.jitsi" -}}
|
||||
{{ $XMPP_GUEST_DOMAIN := .Env.XMPP_GUEST_DOMAIN | default "guest.meet.jitsi" -}}
|
||||
{{ $XMPP_MUC_DOMAIN := .Env.XMPP_MUC_DOMAIN | default "muc.meet.jitsi" -}}
|
||||
{{ $XMPP_MUC_DOMAIN_PREFIX := (split "." $XMPP_MUC_DOMAIN)._0 -}}
|
||||
|
||||
// Begin default config overrides.
|
||||
|
||||
@@ -30,7 +31,7 @@ config.hosts.muc = '{{ $XMPP_MUC_DOMAIN }}';
|
||||
{{ if $ENABLE_AUTH -}}
|
||||
{{ if $ENABLE_GUESTS -}}
|
||||
// When using authentication, domain for guest users.
|
||||
config.hosts.anonymousdomain = '{{ .Env.XMPP_GUEST_DOMAIN }}';
|
||||
config.hosts.anonymousdomain = '{{ $XMPP_GUEST_DOMAIN }}';
|
||||
{{ end -}}
|
||||
// Domain for authenticated users. Defaults to <domain>.
|
||||
config.hosts.authdomain = '{{ $XMPP_DOMAIN }}';
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
if [[ $DISABLE_HTTPS -ne 1 ]] && \
|
||||
[[ $ENABLE_LETSENCRYPT -eq 1 ]]; then
|
||||
if [[ $DISABLE_HTTPS -ne 1 ]] && [[ $ENABLE_LETSENCRYPT -eq 1 ]]; then
|
||||
exec cron -f
|
||||
else
|
||||
# if cron should not be started,
|
||||
|
||||
Reference in New Issue
Block a user