mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-02 07:31:26 +00:00
initrd modules: move passwd and nsswitch back to initrd-ssh
Partially reverts commit 901163c0c7
.
This has broken remote SSH into initrd because ${cfg.shell} is not
expanded. Also, nsswitch is useless without libnss_files.so which
are installed by initrd-ssh.
This commit is contained in:
parent
815ff00ee0
commit
1d70e2fb75
@ -101,6 +101,8 @@ in
|
||||
mount -t devpts devpts /dev/pts
|
||||
|
||||
echo '${cfg.shell}' > /etc/shells
|
||||
echo 'root:x:0:0:root:/root:${cfg.shell}' > /etc/passwd
|
||||
echo 'passwd: files' > /etc/nsswitch.conf
|
||||
|
||||
mkdir -p /var/log
|
||||
touch /var/log/lastlog
|
||||
|
@ -72,11 +72,6 @@ mkdir -p /run
|
||||
mount -t tmpfs -o "mode=0755,size=@runSize@" tmpfs /run
|
||||
|
||||
|
||||
# Initialise /etc.
|
||||
echo 'root:x:0:0:root:/root:${cfg.shell}' > /etc/passwd
|
||||
echo 'passwd: files' > /etc/nsswitch.conf
|
||||
|
||||
|
||||
# Process the kernel command line.
|
||||
export stage2Init=/init
|
||||
for o in $(cat /proc/cmdline); do
|
||||
|
Loading…
Reference in New Issue
Block a user