From feb2d83df383564ef3c3049ef8feb55d51a613f7 Mon Sep 17 00:00:00 2001 From: rhys Date: Wed, 7 Dec 2022 14:25:00 +0000 Subject: [PATCH] Changes to allow a user to set the max participants on a jitsi conference --- docs/configuring-playbook-jitsi.md | 10 ++++++++++ roles/custom/matrix-jitsi/defaults/main.yml | 5 +++++ roles/custom/matrix-jitsi/templates/prosody/env.j2 | 3 +++ 3 files changed, 18 insertions(+) diff --git a/docs/configuring-playbook-jitsi.md b/docs/configuring-playbook-jitsi.md index 4c29b3eb8..c58ee85a7 100644 --- a/docs/configuring-playbook-jitsi.md +++ b/docs/configuring-playbook-jitsi.md @@ -127,6 +127,16 @@ Read how it works [here](https://github.com/jitsi/jitsi-videobridge/blob/master/ You may want to **limit the maximum video resolution**, to save up resources on both server and clients. +## (Optional) Specify a Max number of participants on a Jitsi conference + +The playbook allows a user to set a max number of participants allowed to join a Jitsi conference. By default there is no limit. + +In order to set the max number of participants add the following variable to your `inventory/host_vars/matrix.DOMAIN/vars.yml` configuration: + +``` +jitsi_max_participants: +``` + ## (Optional) Additional JVBs By default, a single JVB ([Jitsi VideoBridge](https://github.com/jitsi/jitsi-videobridge)) is deployed on the same host as the Matrix server. To allow more video-conferences to happen at the same time, you may need to provision additional JVB services on other hosts. diff --git a/roles/custom/matrix-jitsi/defaults/main.yml b/roles/custom/matrix-jitsi/defaults/main.yml index c2d5948da..8369a1f02 100644 --- a/roles/custom/matrix-jitsi/defaults/main.yml +++ b/roles/custom/matrix-jitsi/defaults/main.yml @@ -277,3 +277,8 @@ matrix_jitsi_jvb_container_rtp_tcp_host_bind_port: "{{ matrix_jitsi_jvb_rtp_tcp_ # # Takes an ":" or "" value (e.g. "127.0.0.1:12090"), or empty string to not expose. matrix_jitsi_jvb_container_colibri_ws_host_bind_port: '' + +# Default max participants to the empty string +# +# The setting requires an integer to be set for usage and allows a user to specify the max number of particpants on a conference. +jitsi_max_participants: '' diff --git a/roles/custom/matrix-jitsi/templates/prosody/env.j2 b/roles/custom/matrix-jitsi/templates/prosody/env.j2 index 941f2c253..a1e87953c 100644 --- a/roles/custom/matrix-jitsi/templates/prosody/env.j2 +++ b/roles/custom/matrix-jitsi/templates/prosody/env.j2 @@ -58,3 +58,6 @@ XMPP_MUC_MODULES= XMPP_INTERNAL_MUC_MODULES= XMPP_RECORDER_DOMAIN={{ matrix_jitsi_recorder_domain }} XMPP_CROSS_DOMAIN=true +{% if jitsi_max_participants is number %} +MAX_PARTICIPANTS={{ jitsi_max_participants }} +{% endif %} \ No newline at end of file