Merge branch 'rspamd-dmarc-exclude' into 'master'

mail-server: add `dmarcReporting.excludeDomains`

See merge request simple-nixos-mailserver/nixos-mailserver!297
This commit is contained in:
Maximilian Bosch 2025-03-23 17:54:05 +00:00
commit 4460e1b22d
2 changed files with 11 additions and 0 deletions

View File

@ -894,6 +894,14 @@ in
The sender name for DMARC reports. Defaults to the organization name.
'';
};
excludeDomains = mkOption {
type = types.listOf types.str;
default = [];
description = ''
List of domains or eSLDs to be excluded from DMARC reports.
'';
};
};
debug = mkOption {

View File

@ -74,6 +74,9 @@ in
org_name = "${cfg.dmarcReporting.organizationName}";
from_name = "${cfg.dmarcReporting.fromName}";
msgid_from = "dmarc-rua";
${lib.optionalString (cfg.dmarcReporting.excludeDomains != []) ''
exclude_domains = ${builtins.toJSON cfg.dmarcReporting.excludeDomains};
''}
}''}
''; };
};