The sys admin's daily grind: Prosody
Speed Chat
Columnist Charly Kühnast has been looking into the options of running an instant messaging back end. He chose a particularly lean and easily extendable version.
Prosody [1] is a lean XMPP (Extensible Messaging and Presence Protocol, formerly known as Jabber) server in Lua. It can speak IPv6, supports encrypted transport and – in the default configuration – very little else. You can, however, extend Prosody with modules to add virtually any kind of functionality you need. The number of modules is nearly into three figures [2].
Setting up a basic configuration is a two-step process: You need to create a user and then set up a domain. For my first steps on my home test network, I will be using example.com
as the domain, but you can easily replace this with another domain when you go live. The following command sets up the user:
sudo prosodyctl adduser charly@example.com
You then need to add the account as the administrator to Prosody's central configuration file prosody.cfg.lua
. The file typically resides below /etc/prosody/
, but it can also live directly in /etc
on older systems. The entry for this is:
admins = { "charly@example.com" }
If you like, you can define multiple admins.
Domains
The next step is to describe the example.com domain. You do this in older versions in prosody.cfg.lua
, but most up-to-date Prosody systems store this in two separate directories: /etc/prosody/conf.avail
and /etc/prosody/conf.d
. You create the example.com.cfg.lua
configuration file in /etc/prosody/conf.avail
. Listing 1 shows that the file only contains a couple of lines.
Listing 1
example.com.cfg.lua
The example.com dummy certificate normally comes free with your distribution, and you can replace it with a self-signed or purchased certificate later. To make sure that Prosody recognizes the new domain, I created a symlink to the configuration in the /etc/prosody/conf.d/
directory:
sudo ln -s /etc/prosody/conf.avail/example.com.cfg.lua /etc/prosody/conf.d/
After restarting the XMPP server by typing the following:
sudo service prosody restart
you can log in to the server as the administrator. If you then create a couple more user accounts, you can put on your reading glasses (if you need them) and start chatting right away!
Infos
- Prosody: https://prosody.im
- Add-on modules for Prosody: https://code.google.com/p/prosody-modules/w/list
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Budgie 10.10 Scheduled for Q1 2025 with a Surprising Desktop Update
If Budgie is your desktop environment of choice, 2025 is going to be a great year for you.
-
Firefox 134 Offers Improvements for Linux Version
Fans of Linux and Firefox rejoice, as there's a new version available that includes some handy updates.
-
Serpent OS Arrives with a New Alpha Release
After months of silence, Ikey Doherty has released a new alpha for his Serpent OS.
-
HashiCorp Cofounder Unveils Ghostty, a Linux Terminal App
Ghostty is a new Linux terminal app that's fast, feature-rich, and offers a platform-native GUI while remaining cross-platform.
-
Fedora Asahi Remix 41 Available for Apple Silicon
If you have an Apple Silicon Mac and you're hoping to install Fedora, you're in luck because the latest release supports the M1 and M2 chips.
-
Systemd Fixes Bug While Facing New Challenger in GNU Shepherd
The systemd developers have fixed a really nasty bug amid the release of the new GNU Shepherd init system.
-
AlmaLinux 10.0 Beta Released
The AlmaLinux OS Foundation has announced the availability of AlmaLinux 10.0 Beta ("Purple Lion") for all supported devices with significant changes.
-
Gnome 47.2 Now Available
Gnome 47.2 is now available for general use but don't expect much in the way of newness, as this is all about improvements and bug fixes.
-
Latest Cinnamon Desktop Releases with a Bold New Look
Just in time for the holidays, the developer of the Cinnamon desktop has shipped a new release to help spice up your eggnog with new features and a new look.
-
Armbian 24.11 Released with Expanded Hardware Support
If you've been waiting for Armbian to support OrangePi 5 Max and Radxa ROCK 5B+, the wait is over.