summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorBrian Olsen <brian@maven-group.org>2018-02-26 23:57:44 +0100
committerJörg Thalheim <joerg@thalheim.io>2018-09-27 14:09:54 +0100
commit0f4e1170540809de4428d9e0f77939b7de8deb6b (patch)
treed6c7332d283922504ff724e58a472d17048efb2d /nixos/modules
parentcdb33d1ddcf3dbd019cffe7849ff4f4409d70890 (diff)
nixos/rspamd: Preserve runtime directory when using socket activation
(cherry picked from commit 458bcc8f7a95874afc21cc58ddef6e87d9924d5a)
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/services/mail/rspamd.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/nixos/modules/services/mail/rspamd.nix b/nixos/modules/services/mail/rspamd.nix
index b3dae60c2c7e0..5ecdd3ef6cf4e 100644
--- a/nixos/modules/services/mail/rspamd.nix
+++ b/nixos/modules/services/mail/rspamd.nix
@@ -308,6 +308,7 @@ in
         ExecStart = "${pkgs.rspamd}/bin/rspamd ${optionalString cfg.debug "-d"} --user=${cfg.user} --group=${cfg.group} --pid=/run/rspamd.pid -c ${rspamdConfFile} -f";
         Restart = "always";
         RuntimeDirectory = "rspamd";
+        RuntimeDirectoryPreserve = mkIf cfg.socketActivation true;
         PrivateTmp = true;
         Sockets = mkIf cfg.socketActivation (concatStringsSep " " allSocketNames);
       };