From ea5c7d553c0f43a971fe75216b595a31dc80af94 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Mon, 21 Mar 2016 18:18:54 +0300 Subject: [PATCH] dspam service: run after postgresql to prevent segfaults --- nixos/modules/services/mail/dspam.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/mail/dspam.nix b/nixos/modules/services/mail/dspam.nix index 46e6f216b21..89076ff0546 100644 --- a/nixos/modules/services/mail/dspam.nix +++ b/nixos/modules/services/mail/dspam.nix @@ -104,6 +104,7 @@ in { systemd.services.dspam = { description = "dspam spam filtering daemon"; wantedBy = [ "multi-user.target" ]; + after = [ "postgresql.service" ]; restartTriggers = [ cfgfile ]; serviceConfig = { @@ -114,7 +115,7 @@ in { RuntimeDirectoryMode = optional (cfg.domainSocket == defaultSock) "0750"; PermissionsStartOnly = true; # DSPAM segfaults on just about every error - Restart = "on-failure"; + Restart = "on-abort"; RestartSec = "1s"; };