summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--nixos/modules/programs/shadow.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/programs/shadow.nix b/nixos/modules/programs/shadow.nix
index 15b083b72d2..7e9133099ed 100644
--- a/nixos/modules/programs/shadow.nix
+++ b/nixos/modules/programs/shadow.nix
@@ -94,7 +94,7 @@ in
         groupmod = { rootOK = true; };
         groupmems = { rootOK = true; };
         groupdel = { rootOK = true; };
-        login = { startSession = true; allowNullPassword = true; showMotd = true; updateWtmp = true; };
+        login = { startSession = !config.boot.isContainer; allowNullPassword = true; showMotd = true; updateWtmp = true; };
         chpasswd = { rootOK = true; };
         chgpasswd = { rootOK = true; };
       };