nixos/syncthing: remove exit code 2 from exit status success

Fix #181713
This commit is contained in:
Christian Kögler 2022-09-11 13:24:51 +02:00 committed by Bjørn Forsman
parent 69063d79d3
commit 11bafe6b5b

View file

@ -529,6 +529,8 @@ in {
}; };
systemd.services = { systemd.services = {
# upstream reference:
# https://github.com/syncthing/syncthing/blob/main/etc/linux-systemd/system/syncthing%40.service
syncthing = mkIf cfg.systemService { syncthing = mkIf cfg.systemService {
description = "Syncthing service"; description = "Syncthing service";
after = [ "network.target" ]; after = [ "network.target" ];
@ -540,7 +542,7 @@ in {
wantedBy = [ "multi-user.target" ]; wantedBy = [ "multi-user.target" ];
serviceConfig = { serviceConfig = {
Restart = "on-failure"; Restart = "on-failure";
SuccessExitStatus = "2 3 4"; SuccessExitStatus = "3 4";
RestartForceExitStatus="3 4"; RestartForceExitStatus="3 4";
User = cfg.user; User = cfg.user;
Group = cfg.group; Group = cfg.group;