Skip to content

Commit

Permalink
systemd: don't restart user-runtime-dir@ on upgrades
Browse files Browse the repository at this point in the history
Likewise logind we should not try to restart this service after upgrade,
the user's current session depends on it.

(cherry picked from commit aa69bb5)
  • Loading branch information
Mic92 committed Sep 28, 2018
1 parent 1e1821c commit 1e9f50f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions nixos/modules/system/boot/systemd.nix
Expand Up @@ -886,6 +886,9 @@ in
#systemd.services.systemd-logind.restartTriggers = [ config.environment.etc."systemd/logind.conf".source ];
systemd.services.systemd-logind.restartIfChanged = false;
systemd.services.systemd-logind.stopIfChanged = false;
# The user-runtime-dir@ service is managed by systemd-logind we should not touch it or else we break the users' sessions.
systemd.services."user-runtime-dir@".stopIfChanged = false;
systemd.services."user-runtime-dir@".restartIfChanged = false;
systemd.services.systemd-journald.restartTriggers = [ config.environment.etc."systemd/journald.conf".source ];
systemd.services.systemd-journald.stopIfChanged = false;
systemd.targets.local-fs.unitConfig.X-StopOnReconfiguration = true;
Expand Down

0 comments on commit 1e9f50f

Please sign in to comment.