Skip to content

Commit

Permalink
prosody: add support for lobby
Browse files Browse the repository at this point in the history
  • Loading branch information
saghul committed Jul 22, 2020
1 parent baed605 commit a81ad73
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ services:
- AUTH_TYPE
- ENABLE_AUTH
- ENABLE_GUESTS
- ENABLE_LOBBY
- GLOBAL_MODULES
- GLOBAL_CONFIG
- LDAP_URL
Expand Down
4 changes: 3 additions & 1 deletion env.example
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ TZ=UTC
# See the "Running behind NAT or on a LAN environment" section in the README
#DOCKER_HOST_ADDRESS=192.168.1.1

# Control whether the lobby feature should be enabled or not
#ENABLE_LOBBY=1

#
# Let's Encrypt configuration
Expand Down Expand Up @@ -94,7 +96,7 @@ TZ=UTC
#JIGASI_SIP_TRANSPORT=UDP

#
# Authentication configuration (see README for details)
# Authentication configuration (see handbook for details)
#

# Enable authentication
Expand Down
17 changes: 17 additions & 0 deletions prosody/rootfs/defaults/conf.d/jitsi-meet.cfg.lua
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ http_default_host = "{{ .Env.XMPP_DOMAIN }}"
{{ $JWT_ALLOW_EMPTY := .Env.JWT_ALLOW_EMPTY | default "0" | toBool }}
{{ $JWT_AUTH_TYPE := .Env.JWT_AUTH_TYPE | default "token" }}
{{ $JWT_TOKEN_AUTH_MODULE := .Env.JWT_TOKEN_AUTH_MODULE | default "token_verification" }}
{{ $ENABLE_LOBBY := .Env.ENABLE_LOBBY | default "0" | toBool }}

{{ if and $ENABLE_AUTH (eq $AUTH_TYPE "jwt") .Env.JWT_ACCEPTED_ISSUERS }}
asap_accepted_issuers = { "{{ join "\",\"" (splitList "," .Env.JWT_ACCEPTED_ISSUERS) }}" }
Expand Down Expand Up @@ -52,6 +53,9 @@ VirtualHost "{{ .Env.XMPP_DOMAIN }}"
"ping";
"speakerstats";
"conference_duration";
{{ if $ENABLE_LOBBY }}
"muc_lobby_rooms";
{{ end }}
{{ if .Env.XMPP_MODULES }}
"{{ join "\";\n\"" (splitList "," .Env.XMPP_MODULES) }}";
{{ end }}
Expand All @@ -60,6 +64,11 @@ VirtualHost "{{ .Env.XMPP_DOMAIN }}"
{{end}}
}

{{ if $ENABLE_LOBBY }}
main_muc = "{{ .Env.XMPP_MUC_DOMAIN }}"
lobby_muc = "lobby.{{ .Env.XMPP_DOMAIN }}"
{{ end }}

speakerstats_component = "speakerstats.{{ .Env.XMPP_DOMAIN }}"
conference_duration_component = "conferenceduration.{{ .Env.XMPP_DOMAIN }}"

Expand Down Expand Up @@ -120,3 +129,11 @@ Component "speakerstats.{{ .Env.XMPP_DOMAIN }}" "speakerstats_component"

Component "conferenceduration.{{ .Env.XMPP_DOMAIN }}" "conference_duration_component"
muc_component = "{{ .Env.XMPP_MUC_DOMAIN }}"

{{ if $ENABLE_LOBBY }}
Component "lobby.{{ .Env.XMPP_DOMAIN }}" "muc"
storage = "memory"
restrict_room_creation = true
muc_room_locking = false
muc_room_default_public_jids = true
{{ end }}

0 comments on commit a81ad73

Please sign in to comment.