nixos/tlsrpt: reuse sender address as envelope sender

This prevents leaking the local user and hostname into the envelope,
which could prevent DKIM signing due to lack of keys for the MX hostname.
This commit is contained in:
Martin Weinelt
2026-03-07 16:11:59 +01:00
parent d902e2856c
commit 77bf0b01d0
+2 -2
View File
@@ -244,12 +244,12 @@ in
type = with types; nullOr str;
default =
if config.services.postfix.enable && config.services.postfix.setSendmail then
"/run/wrappers/bin/sendmail -i -t"
"/run/wrappers/bin/sendmail -i -t -f ${cfg.reportd.settings.sender_address}"
else
null;
defaultText = lib.literalExpression ''
if config.services.postfix.enable && config.services.postfix.setSendmail then
"/run/wrappers/bin/sendmail -i -t"
"/run/wrappers/bin/sendmail -i -t -f $${cfg.reportd.settings.sender_address}"
else
null
'';