SET UP YOUR CHAT SERVER
1. INSTALL PROSODY
Open Terminal on your Raspberry Pi, or connect via SSH, and run the command sudo apt-get install prosody , then press Y to confirm you want to install the software on your device. In the next step, you’ll need to change your configuration, so run
sudo nano /etc/prosody/prosody.cfg.lua .
3. RESTART AND ADD AN ADMINISTRATOR
Run the command sudo /etc/init.d/prosody restart to restart Prosody. Next, add an administrator account with the command sudo prosodyctl adduser admin@yourdomain —for example, sudo prosodyctl adduser admin@192.168.1.2 . You’re asked to type an administrator password. Do so, and press Return. Retype the password, then press Return once again.
5. MAKE IT ACCESSIBLE OVER THE INTERNET
If you only want to use the chat server in your home or office, this step isn’t necessary. However, if you want to be able to chat to people in the world at large, follow the steps outlined in “Opening Your Chats to the World Wide Web” (see page 61).
2. MODIFY CONFIG FILE
Scroll to the section labeled “Virtual Hosts” and change
example.com to your domain—for example, 192.168.1.2 . Scroll up to the section named “Server Wide Settings” and, under“Admins,” change, to admins = {“admin@yourip”} — for example, admins = {“admin@192.168.1.2”} . Next, search for the words “allow_ registration” and change to true . Press Ctrl-X, Y, then Return to save and exit.
4. GENERATE AN SSL CERTIFICATE
This step is optional, but recommended. At this stage, you may wish to generate an SSL certificate to allow messaging clients to connect securely to your server. Follow the steps in “Securing Your Chats” (opposite) to do this.
6. CONNECT WITH AN XMPP CLIENT
Finally, use Pidgin, or another XMPP- compatible program, to connect to your chat server. Provide the details to your friends or co- workers to make sure that they can connect, too. And that’s it—you’re ready to chat away to your heart’s content.