]> Git — Sourcephile - sourcephile-nix.git/blob - hosts/mermet/rspamd/sourcephile.fr.nix
nix: update to nixos-24.11
[sourcephile-nix.git] / hosts / mermet / rspamd / sourcephile.fr.nix
1 { config, inputs, hostName, ... }:
2 let
3 inherit (config.services) rspamd;
4 domain = "sourcephile.fr";
5 selector = "20200101";
6 in
7 {
8 services.rspamd.dkimSelectorMap = ''
9 mermet ${selector}
10 ${domain} ${selector}
11 '';
12 # rspamadm dkim_keygen -d sourcephile.fr -s 20200101 -b 4096 -t rsa -k /proc/self/fd/3 3>&1 >>hosts/mermet/rspamd/sourcephile.fr.nix |
13 # pass insert -m hosts/mermet/rspamd/dkim/sourcephile.fr/20200101.key
14 services.knot.zones."${domain}".data = ''
15 20200101._domainkey IN TXT ( "v=DKIM1; k=rsa; "
16 "p=MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA7EKzverbG+5JF+yFjH3MrxLyauiHyLqBbV/8LEMunoKXF8sqhBpQtAQXruLqsyUkxR/4CAyPMyzmcdrU43boMj9yFqLrg/kEz2RIvai9jXBqRoWRW1y7F0LbZmdtOTncuDSP8Zzo02XUzsOC4f/C3tEQHS5rc"
17 "hzfhU5FY1CeO6eBMV79qKBOvGMKahQTrrtU6olAAJxOhn6wRuwSf"
18 "+m3on1OqiuXYYIgNHKdRhJ8gDwIm/3LEpYMD0gTgJiyclCLoLGHGtKZy1Wf9xV9/7V6fHE4JW5SDivwslVTL+KPXOlIpo5NDHpMxPYOcIg2K4Rj/j7jhavo+fG43q1LhwaPkEMQMbplgnjeMY8300odRiklTkMMpH0m35ZNeHQJSRpEtV8y5xUNxVaGzfqX5iStwV/mQ1Kn"
19 "ZSe8ORTNq+eTTFnDk6zdUXjagcf0wO6QsSTeAz/G8CqOBbwmrU+q"
20 "F8WbGAeRnhz51mH6fTTfsQ1nwjAiF4ou+eQGTkTMN23KkCKpuozJnxqx4DCEr6J1bL83fhXw7CgcfgKgTOk/HFJpeiGhqodw18r4DWBA6G57z9utm7Mr/9SoVnMq6iK9iEcbCllLR8Sz4viatLSRzhodbk7hfvXS3jmCFjILAjFmA7aMTemDMBDQhpAGF9F8sjFUbEJIZjK"
21 "rWWtSTdO8DilDqN8CAwEAAQ=="
22 )
23 '';
24 systemd.services.rspamd.serviceConfig = {
25 LoadCredentialEncrypted = [
26 "${domain}.${selector}.key:${./. + "/${domain}/${selector}.dkim.key.cred"}"
27 ];
28 };
29 }