Prosody
Prosody is a light-weight, easy to configure, XMPP server. XMPP is an open and extensible Internet protocol used for communications, presence, identification, authentication etc. It's a big part of the Semantic Web movement which is all about achieving the functionality we need using open standards instead of specific applications.
Contents
Configuration
The prosody configuration is in /etc/prosody with a similar style to Apache or Nginx where individual site's configuration each exist in their own file in the conf.avail sub-directory usually having a filename matching the domain name. Sites are then enabled by creating sym-links in the conf.d sub-directory pointing to the available sites.
Here's an example configurtion file for a specific domain which is set up as a chatroom server starting with the familiar VirtualHost directive to indicate the domain that this configuration covers.
VirtualHost "xmpp.organicdesign.nz"
ssl = {
key = "/etc/prosody/certs/xmpp.organicdesign.nz.key";
certificate = "/etc/prosody/certs/xmpp.organicdesign.nz.crt";
}
-- use an empty admins list to disable all remote administration functions
admins = { "admin@xmpp.organicdesign.nz" }
Component "conference.xmpp.organicdesign.nz" "muc"
name = "The dharma.casa XMPP chatrooms server"
restrict_room_creation = true
allow_registration = false
c2s_require_encryption = true
s2s_require_encryption = true
modules_enabled = {
"tls",
"roster",
"register"
}
Chatrooms
todo: the domain of the chat server is the domain of the "muc" component as as defined in the config, in our case conference.xmpp.organicdesign.nz.
SSL
Todo: import script needed for LE certs, can use LE's hook, and symlinks for certs using alt-names
prosodyctl --root cert import /etc/letsencrypt/live