|
| 1 | +#!/usr/bin/env bash |
| 2 | + |
| 3 | +# Copyright (c) 2021-2025 community-scripts ORG |
| 4 | +# Author: Slaviša Arežina (tremor021) |
| 5 | +# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE |
| 6 | +# Source: https://github.com/jitsi/jitsi-meet |
| 7 | + |
| 8 | +source /dev/stdin <<<"$FUNCTIONS_FILE_PATH" |
| 9 | +color |
| 10 | +verb_ip6 |
| 11 | +catch_errors |
| 12 | +setting_up_container |
| 13 | +network_check |
| 14 | +update_os |
| 15 | + |
| 16 | +msg_info "Installing Dependencies" |
| 17 | +$STD apt-get install -y \ |
| 18 | + apt-transport-https \ |
| 19 | + lsb-release \ |
| 20 | + debconf-utils |
| 21 | +msg_ok "Installed Dependencies" |
| 22 | + |
| 23 | +msg_info "Setting up repositories" |
| 24 | +curl -fsSL https://prosody.im/files/prosody-debian-packages.key -o /etc/apt/keyrings/prosody-debian-packages.key |
| 25 | +echo "deb [signed-by=/etc/apt/keyrings/prosody-debian-packages.key] http://packages.prosody.im/debian $(lsb_release -sc) main" >/etc/apt/sources.list.d/prosody-debian-packages.list |
| 26 | +curl -fsSL https://download.jitsi.org/jitsi-key.gpg.key | gpg --dearmor -o /usr/share/keyrings/jitsi-keyring.gpg |
| 27 | +echo "deb [signed-by=/usr/share/keyrings/jitsi-keyring.gpg] https://download.jitsi.org stable/" >/etc/apt/sources.list.d/jitsi-stable.list |
| 28 | +$STD apt-get update |
| 29 | +msg_ok "Done setting up repositories" |
| 30 | + |
| 31 | +msg_info "Installing jitsi-meet" |
| 32 | +IP=$(hostname -I | awk '{print $1}') |
| 33 | +PASS="$(openssl rand -base64 18 | cut -c1-13)" |
| 34 | +SECRET="$(openssl rand -base64 18 | cut -c1-13)" |
| 35 | +JVBSECRET="$(openssl rand -base64 18 | cut -c1-13)" |
| 36 | +echo "jicofo jicofo/jicofo-authpassword password $PASS" | debconf-set-selections |
| 37 | +echo "jitsi-meet-prosody jicofo/jicofo-authpassword password $PASS" | debconf-set-selections |
| 38 | +echo "jitsi-meet-prosody jitsi-meet-prosody/jvb-hostname string $IP" | debconf-set-selections |
| 39 | +echo "jitsi-meet-prosody jitsi-meet-prosody/turn-secret string $SECRET" | debconf-set-selections |
| 40 | +echo "jitsi-meet-turnserver jitsi-meet-turnserver/jvb-hostname string $IP" | debconf-set-selections |
| 41 | +echo "jitsi-meet-web-config jitsi-meet/cert-choice select Generate a new self-signed certificate" | debconf-set-selections |
| 42 | +echo "jitsi-meet-web-config jitsi-meet/cert-path-crt string '/var/lib/prosody/auth.$IP.crt'" | debconf-set-selections |
| 43 | +echo "jitsi-meet-web-config jitsi-meet/cert-path-key string '/var/lib/prosody/$IP.key'" | debconf-set-selections |
| 44 | +echo "jitsi-meet-web-config jitsi-meet/email string ''" | debconf-set-selections |
| 45 | +echo "jitsi-meet-web-config jitsi-meet/jaas-choice boolean false" | debconf-set-selections |
| 46 | +echo "jitsi-meet-web-config jitsi-meet/jvb-hostname string $IP" | debconf-set-selections |
| 47 | +echo "jicofo jitsi-videobridge/jvb-hostname string $IP" | debconf-set-selections |
| 48 | +echo "jitsi-meet-prosody jitsi-videobridge/jvb-hostname string $IP" | debconf-set-selections |
| 49 | +echo "jitsi-meet-turnserver jitsi-videobridge/jvb-hostname string $IP" | debconf-set-selections |
| 50 | +echo "jitsi-meet-web-config jitsi-videobridge/jvb-hostname string $IP" | debconf-set-selections |
| 51 | +echo "jitsi-videobridge2 jitsi-videobridge/jvb-hostname string $IP" | debconf-set-selections |
| 52 | +echo "jitsi-meet-prosody jitsi-videobridge/jvbsecret password $JVBSECRET" | debconf-set-selections |
| 53 | +echo "jitsi-videobridge2 jitsi-videobridge/jvbsecret password $JVBSECRET" | debconf-set-selections |
| 54 | +$STD apt-get install -y \ |
| 55 | + lua5.2 \ |
| 56 | + jitsi-meet |
| 57 | +msg_ok "Installed jitsi-meet" |
| 58 | + |
| 59 | +motd_ssh |
| 60 | +customize |
| 61 | + |
| 62 | +msg_info "Cleaning up" |
| 63 | +$STD apt-get -y autoremove |
| 64 | +$STD apt-get -y autoclean |
| 65 | +msg_ok "Cleaned" |
0 commit comments