Raspberry Pi, an email with Citadel Server
Warning : This article has been automatically translated by Google Translate
Danger : This article has been automatically translated by Google Translate
After the standard tool that is Postfix (see the article here), I wanted to test a more comprehensive tool : Citadel.
- POP3 email retrieval, IMAP
- Calendar WebDAV, CalDAV
- Push to mobile
- Embedded web server and database
You will see at the end that the picture is not so rosy !
- As at the beginning of tutorial, a full update of the system is necessary !
sudo apt-get update && sudo apt - get upgrade
- Install Inadyn to have your domain name or use the domain you already own. You can find all Info for Inadyn in this article.
- Change the/etc/hosts file
127.0.0.1 <your domain name>
- Change the file/etc/hostname
<your domain name>
- Restart Raspberry Pi
- Install all the Citadel tools
sudo apt - get install citadel-suite
- During the installation, a series of questions will be asked :
- The first request which will be able to connect to the system for the sending/receiving of emails. By default the value is everyone with the IP 0.0.0.0. You can change the value if you want to restrict access. Attention if you put * It may be difficult with a listen on IPv6 addresses.
- The authentication method.
I chose Internal. It's Citadel that will manage everything. The Host method may also be appropriate if you want only people with an account on the machine to be able to have emails.
- The administrator account
Unless you want a particular name, no reason to change. If during the previous stage you selected “Internal”, the account must already exist.
- The password of the administrator. Pas besoin d’expliquer 😉 A saisir deux fois
- Integration of the Web interface
You have the choice between Apache or the embedded Web server. The integrated server is presented as very light and powerful. Not very well familiar with Apache (oui je reste fan de Nginx 🙂 ) I chose the internal server.
- The default port. I have no other service to rotate so I keep the port 80
- The HTTPS port. By default 443, I have not touched.
- The default language. Either you force the value to all or you leave the choice to the user with the value “User defined” (my choice)
- The installation resumes
- At the end of the installation things can get complicated with an error message sent on all consoles :
This comes from the absence of the management of IPv6 in the version used by Raspbian
To solve the problem, the solution is to enter the following command to enable the management of IPv6 and then restart the service
sudo modprobe ipv6 sudo service citadel restart
The first command loads the module but if Pi Raspberry restart it again to redo. To correct permanently, need to add the module in the file/etc/modules
sudo echo "ipv6" >> /etc/modules
- In theory, It has the air to operate, access through the web interface with operational air. However there is still a small error :
Message from syslogd@raspberrypi at Apr 21 12:35:35 ... citserver: Failed to adjust ownership of: /etc/citadel/netconfigs/7 [No. such file or directory]
To solve this, We must create the missing directory and as owner user citadel
sudo mkdir/etc/citadel/netconfigs sudo chown citadel:citadel/etc/citadel/netconfigs sudo service citadel restart
- By connecting to the web interface (Home I took HTTPS) This is the screen I get :
- If you need to change the configuration you can rerun the following command :
And for me I y pass as the admin user was not recognized in the login screen. En plus l’interface de connexion ne fonctionne pas sous Safari 🙁
- You can return to the login page, Enter user and password set during the setup and tadáaáá :
- Go to the part of administration to configure the server
- Fill the area on fields Local host aliases and Directory domains. This is the area where Citadel will receive emails. It's the area of the stage 2 If you go through a domain on Inadyn.
- If you return in the part of the administration you can manage users and their rights
- You can now receive and send emails from the Web interface
Then I honestly struggled with this tool. First my personal taste : I dislike the interface. OK it does everything but I find it ergonomic !
Then I spent as a noob of hours testing the sending mail on Outlook address. By finding (finally) the Citadel log located in/var/log/mail (Yes I know I have trouble at times !), It turns out that as I use a no ip domain, Outlook.com refuses mail from servers with dynamic IP. So if you have a dynamic IP email may not be received by some recipients.
Finally, the SMTP relay. There also I struggled to eventually abandon ! To pass above the Outlook problem I wanted to go through the gmail SMTP. Not Bowl must be TLS authentication and Citadel cannot tell ! Ditto for Free.
Short for the first time I do a tutorial without being really pleased with the result because in the end the tool does not my point of view to go after things ! Me too because in the end I have not tested (yet) securing with SSL certificates.
I expect your tricks on this tool which has the advantage of being simple (When we know how) and complete (from a functionality perspective) 🙂