From 2bfb49f2b69a87aeb7a2e4e9f79354b4dbf5d7fa Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sun, 17 Apr 2022 22:46:29 +0200 Subject: jitsi/jvb: disable bandwith estimation --- roles/apps/jitsi/meet/tasks/main.yml | 11 +++++++++++ roles/apps/jitsi/meet/templates/pod-spec.yml.j2 | 4 ++++ 2 files changed, 15 insertions(+) diff --git a/roles/apps/jitsi/meet/tasks/main.yml b/roles/apps/jitsi/meet/tasks/main.yml index b9dcbeb0..a2624024 100644 --- a/roles/apps/jitsi/meet/tasks/main.yml +++ b/roles/apps/jitsi/meet/tasks/main.yml @@ -55,6 +55,14 @@ dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" mode: 0750 +- name: generate generic jvb cont-init script + copy: + content: | + #!/usr/bin/with-contenv bash + echo "videobridge.cc.trust-bwe=false" >> /config/jvb.conf + dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" + mode: 0750 + - name: configure base pod config hash items set_fact: @@ -62,6 +70,9 @@ - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" properties: - checksum + - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" + properties: + - checksum kubernetes_standalone_pod_config_hash_items_streamui: [] - name: configure stream-ui pod config hash items diff --git a/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 b/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 index dfff54bb..4137cec4 100644 --- a/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 +++ b/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 @@ -212,6 +212,10 @@ containers: hostPort: {{ jitsi_meet_jvb_port }} hostIP: "{{ external_ip | default(ansible_default_ipv4.address) }}" volumeMounts: + - name: scripts + subPath: jvb/cont-init.sh + mountPath: /etc/cont-init.d/99-k8s + readOnly: yes - name: config subPath: jvb mountPath: /config -- cgit v1.2.3 From c53f616457f52ce65c28503b80c4a8b2c0c01cfa Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Mon, 18 Apr 2022 23:16:42 +0200 Subject: jitsi/meet: cleanup and fixes for jvb config --- inventory/host_vars/glt-meet1.yml | 2 +- inventory/host_vars/glt-meet2.yml | 10 ++- roles/apps/jitsi/meet/defaults/main.yml | 10 ++- roles/apps/jitsi/meet/tasks/main.yml | 96 ++++++++++++++----------- roles/apps/jitsi/meet/templates/pod-spec.yml.j2 | 18 +++-- spreadspace/host_vars/glt-meet2.yml | 34 ++++----- 6 files changed, 101 insertions(+), 69 deletions(-) diff --git a/inventory/host_vars/glt-meet1.yml b/inventory/host_vars/glt-meet1.yml index efac6129..b6e13caf 100644 --- a/inventory/host_vars/glt-meet1.yml +++ b/inventory/host_vars/glt-meet1.yml @@ -33,7 +33,7 @@ jitsi_meet_hostname: meet1.linuxtage.at jitsi_meet_p2p_enable: no jitsi_meet_require_display_name: yes -jitsi_resolution: +jitsi_meet_resolution: default: width: 1920 height: 1080 diff --git a/inventory/host_vars/glt-meet2.yml b/inventory/host_vars/glt-meet2.yml index 7ed228e1..1346c389 100644 --- a/inventory/host_vars/glt-meet2.yml +++ b/inventory/host_vars/glt-meet2.yml @@ -33,7 +33,7 @@ jitsi_meet_hostname: meet2.linuxtage.at jitsi_meet_p2p_enable: no jitsi_meet_require_display_name: yes -jitsi_resolution: +jitsi_meet_resolution: default: width: 1920 height: 1080 @@ -41,6 +41,14 @@ jitsi_resolution: width: 1280 height: 720 +jitsi_meet_jvb_config_extra: | + videobridge { + cc { + trust-bwe = false + onstage-preferred-framerate = 25 + } + } + jitsi_meet_secrets: "{{ vault_jitsi_meet_secrets }}" jitsi_meet_auth: diff --git a/roles/apps/jitsi/meet/defaults/main.yml b/roles/apps/jitsi/meet/defaults/main.yml index 4885d827..f60e8ad9 100644 --- a/roles/apps/jitsi/meet/defaults/main.yml +++ b/roles/apps/jitsi/meet/defaults/main.yml @@ -13,7 +13,7 @@ jitsi_meet_p2p_enable: yes jitsi_meet_timezone: Europe/Vienna -# jitsi_resolution: +# jitsi_meet_resolution: # default: # width: 1280 # height: 720 @@ -21,6 +21,14 @@ jitsi_meet_timezone: Europe/Vienna # width: 320 # height: 180 +# jitsi_meet_jvb_config_extra: | +# videobridge { +# cc { +# trust-bwe = false +# onstage-preferred-framerate = 25 +# } +# } + ### generate these using: openssl rand -hex 16 # jitsi_meet_secrets: # jicofo_component_secret: "" ### only needed for versions older than stable-5765-1 diff --git a/roles/apps/jitsi/meet/tasks/main.yml b/roles/apps/jitsi/meet/tasks/main.yml index a2624024..b16fad07 100644 --- a/roles/apps/jitsi/meet/tasks/main.yml +++ b/roles/apps/jitsi/meet/tasks/main.yml @@ -9,6 +9,32 @@ path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/{{ item }}" state: directory +- name: configure base pod config hash items + set_fact: + kubernetes_standalone_pod_config_hash_items_base: + - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" + properties: + - checksum + kubernetes_standalone_pod_config_hash_items_streamui: [] + kubernetes_standalone_pod_config_hash_items_jvb_conf_extra: [] + +- name: generate generic prosody cont-init script + copy: + content: | + #!/usr/bin/with-contenv bash + sed -e 's#^\(component_interface\s*=\)#-- \1#g' -i /config/prosody.cfg.lua + {% if jitsi_meet_auth is defined %} + + echo "authentication enabled:" + {% for username, password in jitsi_meet_auth.users.items() %} + echo " * registering user: {{ username }}" + prosodyctl --config "/config/prosody.cfg.lua" register "{{ username }}" $XMPP_DOMAIN "{{ password }}" + {% endfor %} + {% endif %} + dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" + mode: 0750 + + - name: generate stream-ui specific cont-init scripts when: jitsi_meet_streamui is defined block: @@ -39,52 +65,38 @@ dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/web/streamui.sh" mode: 0755 -- name: generate generic prosody cont-init script - copy: - content: | - #!/usr/bin/with-contenv bash - sed -e 's#^\(component_interface\s*=\)#-- \1#g' -i /config/prosody.cfg.lua - {% if jitsi_meet_auth is defined %} + - name: configure stream-ui pod config hash items + set_fact: + kubernetes_standalone_pod_config_hash_items_streamui: + - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/streamui.sh" + properties: + - checksum + - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/web/streamui.sh" + properties: + - checksum - echo "authentication enabled:" - {% for username, password in jitsi_meet_auth.users.items() %} - echo " * registering user: {{ username }}" - prosodyctl --config "/config/prosody.cfg.lua" register "{{ username }}" $XMPP_DOMAIN "{{ password }}" - {% endfor %} - {% endif %} - dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" - mode: 0750 -- name: generate generic jvb cont-init script - copy: - content: | - #!/usr/bin/with-contenv bash - echo "videobridge.cc.trust-bwe=false" >> /config/jvb.conf - dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" - mode: 0750 +- name: generate jvb cont-init script for extra config snippet + when: jitsi_meet_jvb_config_extra is defined + block: + - name: add jvb extra config snippet to cont-init script of jvb + copy: + content: | + #!/usr/bin/with-contenv bash + cat << EOF >> /config/jvb.conf + {{ jitsi_meet_jvb_config_extra }} + EOF + dest: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" + mode: 0750 -- name: configure base pod config hash items - set_fact: - kubernetes_standalone_pod_config_hash_items_base: - - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/cont-init.sh" - properties: - - checksum - - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" - properties: - - checksum - kubernetes_standalone_pod_config_hash_items_streamui: [] + - name: configure jvb extra config pod config hash items + set_fact: + kubernetes_standalone_pod_config_hash_items_jvb_conf_extra: + - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/jvb/cont-init.sh" + properties: + - checksum -- name: configure stream-ui pod config hash items - when: jitsi_meet_streamui is defined - set_fact: - kubernetes_standalone_pod_config_hash_items_streamui: - - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/streamui.sh" - properties: - - checksum - - path: "{{ jitsi_meet_base_path }}/{{ jitsi_meet_inst_name }}/scripts/prosody/streamui.sh" - properties: - - checksum - name: install pod manifest vars: @@ -92,7 +104,7 @@ name: "jitsi-meet-{{ jitsi_meet_inst_name }}" spec: "{{ lookup('template', 'pod-spec.yml.j2') }}" mode: "0600" - config_hash_items: "{{ kubernetes_standalone_pod_config_hash_items_base + kubernetes_standalone_pod_config_hash_items_streamui }}" + config_hash_items: "{{ kubernetes_standalone_pod_config_hash_items_base + kubernetes_standalone_pod_config_hash_items_streamui + kubernetes_standalone_pod_config_hash_items_jvb_conf_extra }}" include_role: name: kubernetes/standalone/pod diff --git a/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 b/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 index 4137cec4..c6fed105 100644 --- a/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 +++ b/roles/apps/jitsi/meet/templates/pod-spec.yml.j2 @@ -183,19 +183,19 @@ containers: - name: TZ value: {{ jitsi_meet_timezone }} -{% if jitsi_resolution is defined %} +{% if jitsi_meet_resolution is defined %} -{% if 'default' in jitsi_resolution %} +{% if 'default' in jitsi_meet_resolution %} - name: RESOLUTION - value: "{{ jitsi_resolution.default.height }}" + value: "{{ jitsi_meet_resolution.default.height }}" - name: RESOLUTION_WIDTH - value: "{{ jitsi_resolution.default.width }}" + value: "{{ jitsi_meet_resolution.default.width }}" {% endif %} -{% if 'min' in jitsi_resolution %} +{% if 'min' in jitsi_meet_resolution %} - name: RESOLUTION_MIN - value: "{{ jitsi_resolution.min.height }}" + value: "{{ jitsi_meet_resolution.min.height }}" - name: RESOLUTION_WIDTH_MIN - value: "{{ jitsi_resolution.min.width }}" + value: "{{ jitsi_meet_resolution.min.width }}" {% endif %} {% endif %} @@ -212,10 +212,12 @@ containers: hostPort: {{ jitsi_meet_jvb_port }} hostIP: "{{ external_ip | default(ansible_default_ipv4.address) }}" volumeMounts: +{% if jitsi_meet_jvb_config_extra is defined %} - name: scripts subPath: jvb/cont-init.sh mountPath: /etc/cont-init.d/99-k8s readOnly: yes +{% endif %} - name: config subPath: jvb mountPath: /config @@ -244,6 +246,8 @@ containers: value: "true" - name: DOCKER_HOST_ADDRESS value: "{{ external_ip | default(ansible_default_ipv4.address) }}" + - name: JVB_WS_SERVER_ID + value: "127.0.0.1" - name: TZ value: {{ jitsi_meet_timezone }} diff --git a/spreadspace/host_vars/glt-meet2.yml b/spreadspace/host_vars/glt-meet2.yml index 3b1365eb..96f9f897 100644 --- a/spreadspace/host_vars/glt-meet2.yml +++ b/spreadspace/host_vars/glt-meet2.yml @@ -1,18 +1,18 @@ $ANSIBLE_VAULT;1.2;AES256;spreadspace -39373164353063616563316237643832396533373839663063383935633063396162353361393366 -3166353463373430616438393366376361376661313131300a333738353236646537656266633431 -36366432646531323738656533613366656264653362653563313432373334313265336265663332 -6631373831396661650a656539353939333435343332336161656430393632333033346633356362 -62383938323462623533383439643730356262393434316366613266383161336465366235653231 -64663366383664316531616264323939343461383134363063373066336462396566336337623232 -63326230313733373662363831326238616462653237303030653366653636373163383134383235 -34303261316362356661303964333539326163316430393836383866663433363834383761333933 -32373838653564393036376565323234333138653663323230353666653239323031383666326435 -39643736363533626262636434623239343231623631613236386265343136303761343839666464 -34623833656136653234393864303835363236663162316132353364653333386538316338346464 -64386533643036323738653965393132376334343435663461636466383239303339643137653263 -62383934326438303131333866623535333061626661633563636635653062663861613961333731 -66623130336362663162303835616162643837376462613135303034363463333535363235613634 -34616366336336323837313736326331633833303632653730323936393135396533346665306134 -66366362366539303332393365376535646666346234643134303435386539373638643733363432 -62363461663737333761313539373935613131373531656632376435613633313830 +63653634373839386431343362316530613563303631396333343630376435646562356561303135 +6133316465333138663739383532663430313937343932660a643532316462656539663239346231 +66643032363066353331313630633933613736323865376565363562663030656434306362393065 +6639633038623864390a323762626461316661323839303866656236303461343432643939313030 +32666664356235383437326562653962373035656132383364633566303364306233653136333161 +34363562343930353632653163383663313736343538663463316265323564643936306138313133 +35316135653438656266633430383163623634393734633133393463393333663133613739656662 +66356133343934666462623365376161613961333766636366663138353139663131636137613634 +66356433643234303466363034333263613665633365623135343364653563383663313066623638 +63623732643438366661616535643238323439366338626235633835346538333939616666636664 +34653831313563623963333661646336396664306530353766393532383165363563646633646230 +62363936343961313263623636333430663365373739616462343761616366393032396138353833 +31613564653139366330303438326662306361383963346133316130303936653162363036613565 +32363231633065306231663562613038313566626233323932343431643137316164333831336539 +32393030623162636266326639316362633139633330656462393130316232366631323161323238 +33663535343264663336616563393837396533366632373965616666353135653937396164343963 +64336364353137396534353836336630636639303530356630376565323566336564 -- cgit v1.2.3 From 4e9254ba4ebd66b52e42134a62d9010690fd024c Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Mon, 18 Apr 2022 23:33:25 +0200 Subject: jitsi/meet: also deploy fixes to meet1.linuxtage.at --- inventory/host_vars/glt-meet1.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/inventory/host_vars/glt-meet1.yml b/inventory/host_vars/glt-meet1.yml index b6e13caf..77d50be3 100644 --- a/inventory/host_vars/glt-meet1.yml +++ b/inventory/host_vars/glt-meet1.yml @@ -41,6 +41,14 @@ jitsi_meet_resolution: width: 1280 height: 720 +jitsi_meet_jvb_config_extra: | + videobridge { + cc { + trust-bwe = false + onstage-preferred-framerate = 25 + } + } + jitsi_meet_secrets: "{{ vault_jitsi_meet_secrets }}" jitsi_meet_auth: -- cgit v1.2.3