Computer Tips - Linux: Install Prosody XMPP server

Date: 2020jun16 Keywords: Jabber, xmpp OS: Linux Q. Linux: Install Prosody XMPP server A. This worked for me 1. Install the package (On RedHat/Fedora/CentOS)
dnf install prosody
2. Set up certificates I use Lets Encrypt which stores its certs in /etc/letsencrypt/live with only root allowed to read. Prosody runs as user prosody so can't read them, so copy them over But they are regularly renewed, so I made a /etc/cron.monthly/prosody-certs.cron script which does:
#!/bin/sh DIR=/etc/prosody/certs/$HOST if [[ ! -d $DIR ]]; then mkdir $DIR fi cp /etc/letsencrypt/live/$HOST/*.pem $DIR chgrp prosody $DIR/*
And ran it:
3. Configure
cd /etc/prosody/conf.d
Copy the example file for each of your hosts 4. Enable and start it
systemctl enable prosody systemctl start prosody
5. Open your firewall and forward from your router (if necessary)
(Add xmpp-client to firewalld to open port 5222 - confusing name)
6. Create users
prosodyctl adduser userid@host
7. Test