The sys admin's daily grind: Prosody
Speed Chat
![](/var/linux_magazin/storage/images/issues/2015/174/charly-s-column-prosody/kuehnast_charly_4.png/648606-1-eng-US/Kuehnast_Charly_4.png_medium.png)
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.
![Learn More](https://www.linux-magazine.com/var/linux_magazin/storage/images/media/linux-magazine-eng-us/images/misc/learn-more/834592-1-eng-US/Learn-More_medium.png)
News
-
NVIDIA Released Driver for Upcoming NVIDIA 560 GPU for Linux
Not only has NVIDIA released the driver for its upcoming CPU series, it's the first release that defaults to using open-source GPU kernel modules.
-
OpenMandriva Lx 24.07 Released
If you’re into rolling release Linux distributions, OpenMandriva ROME has a new snapshot with a new kernel.
-
Kernel 6.10 Available for General Usage
Linus Torvalds has released the 6.10 kernel and it includes significant performance increases for Intel Core hybrid systems and more.
-
TUXEDO Computers Releases InfinityBook Pro 14 Gen9 Laptop
Sporting either AMD or Intel CPUs, the TUXEDO InfinityBook Pro 14 is an extremely compact, lightweight, sturdy powerhouse.
-
Google Extends Support for Linux Kernels Used for Android
Because the LTS Linux kernel releases are so important to Android, Google has decided to extend the support period beyond that offered by the kernel development team.
-
Linux Mint 22 Stable Delayed
If you're anxious about getting your hands on the stable release of Linux Mint 22, it looks as if you're going to have to wait a bit longer.
-
Nitrux 3.5.1 Available for Install
The latest version of the immutable, systemd-free distribution includes an updated kernel and NVIDIA driver.
-
Debian 12.6 Released with Plenty of Bug Fixes and Updates
The sixth update to Debian "Bookworm" is all about security mitigations and making adjustments for some "serious problems."
-
Canonical Offers 12-Year LTS for Open Source Docker Images
Canonical is expanding its LTS offering to reach beyond the DEB packages with a new distro-less Docker image.
-
Plasma Desktop 6.1 Released with Several Enhancements
If you're a fan of Plasma Desktop, you should be excited about this new point release.