From ad24ed9d2a5f993e934058ced1cf70d29d1d693d Mon Sep 17 00:00:00 2001 From: niten Date: Thu, 28 Sep 2023 14:22:47 -0700 Subject: [PATCH] Need to define key/signing tables earlier --- dkim.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dkim.nix b/dkim.nix index eb5b9d4..b707ab3 100644 --- a/dkim.nix +++ b/dkim.nix @@ -32,6 +32,9 @@ let pkgs.writeText "opendkim-signing-table" (concatStringsSep "\n" (map (dom: "${dom} ${dom}") domains)); + keyTable = makeKeyTable cfg.state-directory cfg.domains; + signingTable = makeSigningTable cfg.domains; + in { options.fudo.mail.dkim = with types; { enable = mkEnableOption "Enable DKIM signature verification."; @@ -93,8 +96,6 @@ in { SyslogSuccess yes LogWhy yes ''; - keyTable = makeKeyTable cfg.state-directory cfg.domains; - signingTable = makeSigningTable cfg.domains; in pkgs.writeText "opendkim.conf" '' Canonicalization relaxed/simple Socket inet:${toString cfg.port}