In this tutorial, I will use the IP address 192.168.0.200, gateway 192.168.0.1 and DNS 184.108.40.206, 220.127.116.11. These settings might differ for you, so you have to replace them where appropriate. You can write the commands below directly in the terminal or remote connect using a SSH client like PuTTY.
Before proceeding further you need to have Raspberry Pi OS Lite / Desktop installed on your Raspberry Pi device. If you don’t already have this, you can use the Tutorial: Installing Raspberry Pi OS to install the Operating System.
- Raspberry Pi 2 or greater
- Power supply
- Micro SD card 8/16GB
- Ethernet cord
1 Update system.
sudo apt-get update && sudo apt-get upgrade -y
2 Configure Network.
sudo nano /etc/dhcpcd.conf
Scroll to the end and the following:
interface eth0 static ip_address=192.168.0.200/24 static routers=192.168.0.1 static domain_name_servers=18.104.22.168 22.214.171.124
Press ctrl + x, and then press y + enter to save.
3 Installing packages.
sudo apt install build-essential curl g++ gettext shared-mime-info libssl-dev zlib1g-dev
Login as root:
wget -q -O - http://easyinstall.citadel.org/install | bash
Select y and press enter.
Accept the terms by writing y and then press enter.
Next press y to install dependencies
Select y and press enter to start the installation.
Now, it’s time to configure Citadel. You’ll be asked to enter a username for the admin user. By default, that’s admin and you can either enter a new value or hit Enter to leave the Citadel email server username unchanged.
Similarly, the installation process prompts you fo enter an admin password. The default password is citadel and you can enter a new value or hit Enter to leave it unchanged. It’s optional but a security best practice to at least change the password.
Once you’ve set a username and password, you’ll need to pick a user for Citadel to run under. The default user is root, so either enter a new value such as citadel, or leave it unchanged. It’s best to create a new user rather than run Citadel email server as root.
Citadel lets you enter a specific IP address for your Raspberry Pi email server to listen in on. At default, Citadel listens on all addresses, so you can leave this unchanged and hit Enter, or select a specific port. I wrote 0.0.0.0 to listen on all addresses using only ipv4.
You’ll need to pick an authentication method. Your options are:
0. Self-contained authentication
1. Host system integrated authentication
2. External LDAP – RDC 2307 POSIX schema
3. External LDAP – MS Active Directory schema
By default, option 0, self-contained authentication, is selected. Unless you need to, leave this unchanged. If you’d like to use a host system integrated authentication method, or external LDAP choices, enter the corresponding number and hit Enter. Otherwise, just leave it at 0 and press Enter.
Lastly, choose a port for the Citadel web user-interface (web UI). If you’re running a web server like Apache or WordPress, you might want to set the HTTP port to 8080, and HTTPS port as 8433. If you aren’t running another web server, you could leave the HTTP port as 80 and HTTPS as 443. When that’s finished, you should be all ready to start using Citadel on the Raspberry Pi!
I will be using port 80 for HTTP and port 443 for HTTPS.
When you’ve successfully installed Citadel email server on the Raspberry Pi, it’s time to actually set it up. Head to your Raspberry Pi’s IP address either on the Pi itself or from a different computer on the same network as your Pi. You can find your Raspberry Pi’s IP address with:
In a browser, head to http://RASPBERRY PI IP ADDRESS/. Then, the Citadel login page should pop up and prompt you for your user name and password. If that’s left unchanged, you’ll enter root and citadel, but if you changed these to custom variables, use those instead.
From here you will be able to configure citadel.