depot/hosts/VEGAS/services/mail/default.nix
2022-01-14 22:49:38 +01:00

19 lines
381 B
Nix

{ tools, ... }:
{
imports = [
./imap.nix
./opendkim.nix
./postfix.nix
./saslauthd.nix
];
services.nginx.virtualHosts."mail.${tools.meta.domain}" = {
enableACME = true;
locations."/".return = "204";
};
security.acme.certs."mail.${tools.meta.domain}".extraDomainNames = map
(x: "${x}.${tools.meta.domain}") [
"mx"
"imap"
"smtp"
];
}