3
0
Fork 0
forked from mirrors/nixpkgs

nixos/dovecot: symlink system-wide config and use it

This commit is contained in:
Nikolay Amiantov 2016-01-10 07:02:24 +03:00
parent 70e77f9b53
commit 39bbac96af

View file

@ -201,6 +201,7 @@ in
};
environment.etc."dovecot/modules".source = modulesDir;
environment.etc."dovecot/dovecot.conf".source = cfg.configFile;
systemd.services.dovecot2 = {
description = "Dovecot IMAP/POP3 server";
@ -208,10 +209,11 @@ in
after = [ "keys.target" "network.target" ];
wants = [ "keys.target" ];
wantedBy = [ "multi-user.target" ];
restartTriggers = [ cfg.configFile ];
serviceConfig = {
ExecStart = "${dovecotPkg}/sbin/dovecot -F -c ${cfg.configFile}";
ExecReload = "${dovecotPkg}/sbin/doveadm reload -c ${cfg.configFile}";
ExecStart = "${dovecotPkg}/sbin/dovecot -F";
ExecReload = "${dovecotPkg}/sbin/doveadm reload";
Restart = "on-failure";
RestartSec = "1s";
StartLimitInterval = "1min";