This guide helps you host your own Jitsi server on a Raspberry Pi 4B. It is adapted from Jitsi's quick install guide and the Jitsi on ARM guide written by crouchingtigerhiddenadam. The biggest difference is this is designed to work with a Pi running Ubuntu Server 21.04 instead of Raspbian.
I did this because I'd rather set up Jitsi Meet on a Raspberry Pi I already own than add a dedicated VPS (and pay AWS's bandwidth costs) just for that. I used Ubuntu 21.04 because I'm more familiar with Ubuntu than with Raspbian, and using an arm64 OS makes the setup easier than on armhf. I also tried to use distribution packages instead of manually downloading individual deb files throughout.
This guide assumes you already have a DNS name set up with an A record pointing to the public IP address of your Raspberry Pi.
You can get this from https://ubuntu.com/download/raspberry-pi - I used the 64-bit image for Raspberry Pi 4. The default username and password on that are both "ubuntu"; it will prompt you to set a new password on first login.
You'll want to set that up the same way you would any other distribution for a Pi, and set yourself up for SSH access if you don't have a conveniently-placed keyboard connected to your Pi. If you're not familiar with how to get started writing that disk image to a microSD card there's a tutorial you can follow at https://ubuntu.com/tutorials/how-to-install-ubuntu-on-your-raspberry-pi#1-overview for this step.
Generally speaking this means you'll need to follow the instructions at https://jitsi.github.io/handbook/docs/devops-guide/devops-guide-quickstart, but stop before the Let's Encrypt certificate step.
In slightly more detail:
I assume you already have an FQDN set up in DNS that you want to use for this Jitsi install - suppose that's jitsi.example.com
.
First, change the hostname on the machine to match that:
sudo hostnamectl set-hostname jitsi.example.com
Then use vim
or your favorite editor to put the same FQDN in the /etc/hosts
file, associating it with your public IP address. This means you'll edit the top of that file so it looks like:
127.0.0.1 localhost
x.x.x.x jitsi.example.com
Where x.x.x.x is your external IP address.
When this is done, test that you can ping your domain name with ping "$(hostname)"
. If it worked, you should see a response from your domain name.
curl https://download.jitsi.org/jitsi-key.gpg.key | sudo sh -c 'gpg --dearmor > /usr/share/keyrings/jitsi-keyring.gpg'
echo 'deb [signed-by=/usr/share/keyrings/jitsi-keyring.gpg] https://download.jitsi.org stable/' | sudo tee /etc/apt/sources.list.d/jitsi-stable.list > /dev/null
Open 80/TCP, 443/TCP and 10000/UDP on your firewall, making sure those ports are forwarded to your Pi if it's behind a NAT.
# Ensure support is available for apt repositories served via HTTPS
sudo apt install apt-transport-https
# Retrieve the latest package versions across all repositories
sudo apt update
# Perform jitsi-meet installation
sudo apt install jitsi-meet
The installer will ask you for the hostname of your Jitsi Meet instance; set that to the same FQDN you entered earlier. Then it'll ask about an SSL certificate; pick "Generate a new self-signed certificate". We'll set up a real SSL cert with Let's Encrypt in the next step.
First, install certbot
from the Ubuntu repositories:
sudo apt install certbot
Then run the script to generate a Let's Encrypt certificate:
sudo /usr/share/jitsi-meet/scripts/install-letsencrypt-cert.sh
At this point you should see the landing page load correctly at https://jitsi.example.com! Yay! Unfortunately we're not done yet, because as you'll see it doesn't actually work if you try to connect multiple clients to a jitsi meeting; we'll fix that in the next step.
This section is cribbed off jitsi-meet issue 6449.
sudo apt install openjdk-8-jdk build-essential libtool maven
sudo systemctl stop prosody jitsi-videobridge2 jicofo
git clone https://github.com/sctplab/usrsctp.git
git clone https://github.com/jitsi/jitsi-sctp
mv ./usrsctp ./jitsi-sctp/usrsctp/
cd ./jitsi-sctp
mvn package -DbuildSctp -DbuildNativeWrapper -DdeployNewJnilib -DskipTests
cp ./jniwrapper/native/target/libjnisctp-linux-aarch64.so \
./jniwrapper/native/src/main/resources/lib/linux/libjnisctp.so
When running mvn package ensure all unit tests are successful. You will see some warnings about "Using platform encoding", but that's fine because we're building on the platform that we intend to run this on anyway.
mvn package
sudo cp ./jniwrapper/native/target/jniwrapper-native-1.0-SNAPSHOT.jar \
/usr/share/jitsi-videobridge/lib/jniwrapper-native-1.0-SNAPSHOT.jar
sudo systemctl start prosody jitsi-videobridge2 jicofo
systemctl status jitsi-videobridge2
Fire up your web browser, start a jitsi meeting, join it from another tab or another device, and check the jitsi logs at sudo less /var/log/jitsi/jvb.log
if something is amiss.
Ok, it is working now
My bad is missed port forwarding for 443 and 10000 port on my router
Success!!!