From e6c72d9c71bb25b6ab598fe2e912212ebe757e8d Mon Sep 17 00:00:00 2001 From: Boris Grozev Date: Tue, 30 Jan 2024 12:20:40 -0600 Subject: [PATCH] Remove PROSODY_ADMINS It is overriden in jitsi-meet.cfg.lua and therefore only usable in visitors mode. Move the declaration to visitors.cfg.lua --- docker-compose.yml | 1 - prosody/rootfs/defaults/conf.d/visitors.cfg.lua | 2 ++ prosody/rootfs/defaults/prosody.cfg.lua | 7 ------- prosody/rootfs/etc/cont-init.d/10-config | 3 --- 4 files changed, 2 insertions(+), 11 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index e06286aa7a..72a0bae4cc 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -242,7 +242,6 @@ services: - LDAP_URL - LDAP_USE_TLS - MAX_PARTICIPANTS - - PROSODY_ADMINS - PROSODY_AUTH_TYPE - PROSODY_C2S_LIMIT - PROSODY_C2S_REQUIRE_ENCRYPTION diff --git a/prosody/rootfs/defaults/conf.d/visitors.cfg.lua b/prosody/rootfs/defaults/conf.d/visitors.cfg.lua index 51520ebe6a..23a0460b49 100644 --- a/prosody/rootfs/defaults/conf.d/visitors.cfg.lua +++ b/prosody/rootfs/defaults/conf.d/visitors.cfg.lua @@ -38,6 +38,8 @@ plugin_paths = { "/prosody-plugins/", "/prosody-plugins-custom" } +admins = { "focus@$XMPP_AUTH_DOMAIN" } + muc_mapper_domain_base = "v{{ $VISITOR_INDEX }}.{{ $VISITORS_XMPP_DOMAIN }}"; muc_mapper_domain_prefix = "{{ $XMPP_MUC_DOMAIN_PREFIX }}"; diff --git a/prosody/rootfs/defaults/prosody.cfg.lua b/prosody/rootfs/defaults/prosody.cfg.lua index 8864b8bdae..5f9b03a6d3 100644 --- a/prosody/rootfs/defaults/prosody.cfg.lua +++ b/prosody/rootfs/defaults/prosody.cfg.lua @@ -13,8 +13,6 @@ {{ $LOG_LEVEL := .Env.LOG_LEVEL | default "info" }} {{ $PROSODY_C2S_LIMIT := .Env.PROSODY_C2S_LIMIT | default "10kb/s" -}} {{ $PROSODY_HTTP_PORT := .Env.PROSODY_HTTP_PORT | default "5280" -}} -{{ $PROSODY_ADMINS := .Env.PROSODY_ADMINS | default "" -}} -{{ $PROSODY_ADMIN_LIST := splitList "," $PROSODY_ADMINS -}} {{ $TRUSTED_PROXIES := .Env.PROSODY_TRUSTED_PROXIES | default "127.0.0.1,::1" -}} {{ $TRUSTED_PROXY_LIST := splitList "," $TRUSTED_PROXIES -}} {{ $PROSODY_S2S_LIMIT := .Env.PROSODY_S2S_LIMIT | default "30kb/s" -}} @@ -47,11 +45,6 @@ -- Settings in this section apply to the whole server and are the default settings -- for any virtual hosts --- This is a (by default, empty) list of accounts that are admins --- for the server. Note that you must create the accounts separately --- (see http://prosody.im/doc/creating_accounts for info) --- Example: admins = { "user1@example.com", "user2@example.net" } -admins = { {{ if .Env.PROSODY_ADMINS }}{{ range $index, $element := $PROSODY_ADMIN_LIST -}}{{ if $index }}, {{ end }}"{{ $element }}"{{ end }}{{ end }} } -- Enable use of libevent for better performance under high load -- For more information see: http://prosody.im/doc/libevent --use_libevent = true; diff --git a/prosody/rootfs/etc/cont-init.d/10-config b/prosody/rootfs/etc/cont-init.d/10-config index e9ebc0e393..4e5d894258 100644 --- a/prosody/rootfs/etc/cont-init.d/10-config +++ b/prosody/rootfs/etc/cont-init.d/10-config @@ -36,9 +36,6 @@ if [[ "$PROSODY_MODE" == "visitors" ]]; then PROSODY_SITE_CFG="visitors.cfg.lua" rm /config/conf.d/jitsi-meet.cfg.lua rm /config/conf.d/brewery.cfg.lua - # force jicofo into auth domain for visitor-mode prosody - [ -z "$XMPP_AUTH_DOMAIN" ] && XMPP_AUTH_DOMAIN="auth.meet.jitsi" - export PROSODY_ADMINS="focus@$XMPP_AUTH_DOMAIN" elif [[ "$PROSODY_MODE" == "brewery" ]]; then echo "Prosody brewery mode, using alternate config" PROSODY_SITE_CFG="brewery.cfg.lua"