docs: add how-to to setup roundcube

This commit is contained in:
Guillaume Girol 2021-12-31 12:00:00 +00:00 committed by lewo
parent 021b5c8f73
commit 7de138037f
2 changed files with 33 additions and 0 deletions

32
docs/add-roundcube.rst Normal file
View File

@ -0,0 +1,32 @@
Add Roundube, a webmail
=======================
The NixOS module for roundcube nearly works out of the box with SNM. By
default, it sets up a nginx virtual host to serve the webmail, other web
servers may require more work.
.. code:: nix
{ config, pkgs, lib, ... }:
with lib;
{
services.roundcube = {
enable = true;
# this is the url of the vhost, not necessarily the same as the fqdn of
# the mailserver
hostName = "webmail.example.com";
extraConfig = ''
# starttls needed for authentication, so the fqdn required to match
# the certificate
$config['smtp_server'] = "tls://${config.mailserver.fqdn}";
$config['smtp_user'] = "%u";
$config['smtp_pass'] = "%p";
'';
};
services.nginx.enable = true;
networking.firewall.allowedTCPPorts = [ 80 443 ];
}

View File

@ -25,6 +25,7 @@ Welcome to NixOS Mailserver's documentation!
backup-guide
add-radicale
add-roundcube
rspamd-tuning
fts
flakes