31 lines
738 B
Nix
31 lines
738 B
Nix
{ config, flake, ... }:
|
|
|
|
{
|
|
mailserver = {
|
|
enable = true;
|
|
fqdn = "mail.${config.pub-solar-os.networking.domain}";
|
|
domains = [ config.pub-solar-os.networking.domain ];
|
|
# Use Let's Encrypt certificates. Note that this needs to set up a stripped
|
|
# down nginx and opens port 80.
|
|
certificateScheme = "acme-nginx";
|
|
};
|
|
|
|
security.acme.acceptTerms = true;
|
|
security.acme.defaults.email = config.pub-solar-os.adminEmail;
|
|
|
|
pub-solar-os.backups.restic.mail = {
|
|
paths = [
|
|
"/var/vmail"
|
|
"/var/dkim"
|
|
];
|
|
timerConfig = {
|
|
OnCalendar = "*-*-* 02:00:00 Etc/UTC";
|
|
};
|
|
initialize = true;
|
|
pruneOpts = [
|
|
"--keep-daily 7"
|
|
"--keep-weekly 4"
|
|
"--keep-monthly 3"
|
|
];
|
|
};
|
|
}
|