mirror of
https://gitlab.com/simple-nixos-mailserver/nixos-mailserver.git
synced 2024-11-11 11:29:17 +05:00
Set mailserver.policydSPFExtraConfig in a debug module
The line type of this option make its concatenation cleaner: the user doesn't have to manually add `\n` to its policydSPFExtraConfig value when debug in set.
This commit is contained in:
parent
ae89eafb81
commit
ee3d38a157
@ -894,6 +894,7 @@ in
|
||||
|
||||
imports = [
|
||||
./mail-server/borgbackup.nix
|
||||
./mail-server/debug.nix
|
||||
./mail-server/rsnapshot.nix
|
||||
./mail-server/clamav.nix
|
||||
./mail-server/monit.nix
|
||||
|
4
mail-server/debug.nix
Normal file
4
mail-server/debug.nix
Normal file
@ -0,0 +1,4 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
mailserver.policydSPFExtraConfig = lib.mkIf config.mailserver.debug "debugLevel = 4";
|
||||
}
|
@ -114,11 +114,7 @@ let
|
||||
(lib.optional cfg.dkimSigning "unix:/run/opendkim/opendkim.sock")
|
||||
++ [ "unix:/run/rspamd/rspamd-milter.sock" ];
|
||||
|
||||
policyd-spf = pkgs.writeText "policyd-spf.conf" (
|
||||
cfg.policydSPFExtraConfig
|
||||
+ (lib.optionalString cfg.debug ''
|
||||
debugLevel = 4
|
||||
''));
|
||||
policyd-spf = pkgs.writeText "policyd-spf.conf" cfg.policydSPFExtraConfig;
|
||||
|
||||
mappedFile = name: "hash:/var/lib/postfix/conf/${name}";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user