summary refs log tree commit diff
diff options
context:
space:
mode:
authorJörg Thalheim <Mic92@users.noreply.github.com>2018-09-28 12:10:02 +0100
committerGitHub <noreply@github.com>2018-09-28 12:10:02 +0100
commit1d65e473e705c7be5ebfe079d0311c3a5eeaf462 (patch)
tree0f54cc738b79a6d488d8126afc28d825f94e0491
parentc917407575edab32c695c23c972fb4a85d795196 (diff)
parentaa69bb5743069f62204433aaa493861bea53755f (diff)
downloadnixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar.gz
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar.bz2
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar.lz
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar.xz
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.tar.zst
nixpkgs-1d65e473e705c7be5ebfe079d0311c3a5eeaf462.zip
Merge pull request #47462 from Mic92/fix-logind-user-temp
systemd: don't restart user-runtime-dir@ on upgrades
-rw-r--r--nixos/modules/system/boot/systemd.nix3
1 files changed, 3 insertions, 0 deletions
diff --git a/nixos/modules/system/boot/systemd.nix b/nixos/modules/system/boot/systemd.nix
index 12e029ae57f..3ac4c02b61f 100644
--- a/nixos/modules/system/boot/systemd.nix
+++ b/nixos/modules/system/boot/systemd.nix
@@ -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;