1
0
mirror of https://github.com/ellmau/nixos.git synced 2025-12-19 09:29:36 +01:00
nixos/modules/server/smailserver.nix

33 lines
800 B
Nix

{ config, pkgs, lib, ... }:
with lib;{
config =
let
cfg = config.elss.server.smailserver;
in
mkIf cfg.enable {
mailserver = {
enable = true;
fqdn = "mail.ellmauthaler.net";
domains = [ "ellmauthaler.net" ];
loginAccounts = {
"ellmau@ellmauthaler.net" = {
aliases = [ "stefan@ellmauthaler.net" "postmaster@ellmauthaler.net" "abuse@ellmauthaler.net" ];
hashedPasswordFile = sops.secrets.ellmauMail.path;
};
};
# use ACME
certificateScheme = 3;
};
sops.secrets = {
ellmauMail = {
owner = mailserver.vmailUserName;
group = mailserver.vmailGroupName;
sopsFile = ../../secrets/server.yaml;
};
};
};
}