(lib.attrsets.filterAttrs (n: v: v.mx.enable) config.myEnv.servers);
# FIXME: increase the id number in modules/private/dns.nix when this
# file change (date -u +'%Y%m%d%H%M%S'Z)
- file = domain: pkgs.writeText "mta-sts-${domain.domain}.txt" ''
- version: STSv1
- mode: testing
- ${builtins.concatStringsSep "\n" (map (v: "mx: ${v}.${domain.mail}") mxes)}
- max_age: 604800
- '';
+ file = domain: pkgs.writeText "mta-sts-${domain.domain}.txt" (
+ builtins.concatStringsSep "\r\n" ([ "version: STSv1" "mode: testing" ]
+ ++ (map (v: "mx: ${v}.${domain.mail}") mxes)
+ ++ [ "max_age: 604800" ]
+ ));
root = pkgs.runCommand "mta-sts_root" {} ''
mkdir -p $out
${builtins.concatStringsSep "\n" (map (d: