summary refs log tree commit diff
path: root/nixos/modules/services/mail/dovecot.nix
diff options
context:
space:
mode:
authorLangston Barrett <langston.barrett@gmail.com>2016-09-07 01:39:18 +0000
committerLangston Barrett <langston.barrett@gmail.com>2016-09-07 01:50:59 +0000
commit492a90f1c94fca326e60ac1e722eb8bb3cf62bb4 (patch)
tree34648227a491a54c57f9b561c306466b64e79076 /nixos/modules/services/mail/dovecot.nix
parent39e197ab1ccad9f1b57c10afe4cfe592a9e40270 (diff)
downloadnixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar.gz
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar.bz2
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar.lz
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar.xz
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.tar.zst
nixpkgs-492a90f1c94fca326e60ac1e722eb8bb3cf62bb4.zip
dovecot service: require mail{User,Group} with sieveScripts
fixes #17702.
Diffstat (limited to 'nixos/modules/services/mail/dovecot.nix')
-rw-r--r--nixos/modules/services/mail/dovecot.nix3
1 files changed, 3 insertions, 0 deletions
diff --git a/nixos/modules/services/mail/dovecot.nix b/nixos/modules/services/mail/dovecot.nix
index f239dda564a..e79d5dadd82 100644
--- a/nixos/modules/services/mail/dovecot.nix
+++ b/nixos/modules/services/mail/dovecot.nix
@@ -271,6 +271,9 @@ in
       { assertion = cfg.showPAMFailure -> cfg.enablePAM;
         message = "dovecot is configured with showPAMFailure while enablePAM is disabled";
       }
+      { assertion = (cfg.sieveScripts != {}) -> ((cfg.mailUser != null) && (cfg.mailGroup != null));
+        message = "dovecot requires mailUser and mailGroup to be set when sieveScripts is set";
+      }
     ];
 
   };