Skip to content

Commit

Permalink
install-device: permit root login with password
Browse files Browse the repository at this point in the history
Allow password login to the installation this allows doing remote installation
via SSH. All that need to be done on the local machine is:
1. Boot from the installation media
2. Set a password with passwd
3. Enable SSH with systemctl start sshd

It is safe as root doesn't have a password by default
and SSH is disabled by default.

Fixes #20718
  • Loading branch information
bachp authored and globin committed Jan 25, 2017
1 parent 0a4943a commit 03ef04f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion nixos/modules/profiles/installation-device.nix
Expand Up @@ -46,7 +46,12 @@ with lib;
'';

# Allow sshd to be started manually through "start sshd".
services.openssh.enable = true;
services.openssh = {
enable = true;
# Allow password login to the installation, if the user sets a password via "passwd"
# It is safe as root doesn't have a password by default and SSH is disabled by default
permitRootLogin = "yes";
};
systemd.services.sshd.wantedBy = mkOverride 50 [];

# Enable wpa_supplicant, but don't start it by default.
Expand Down

0 comments on commit 03ef04f

Please sign in to comment.