mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-01 07:01:54 +00:00
nixos-enter: Ensures presence of full /sys tree.
This partially reverts a change from e88f28965a
which removed the `mount --rbind /sys`.
While true that the activation scripts will mount `sysfs` at `/sys`,
none of the mountpoints lower in the `/sys` tree are handled by the
activation script, which includes `efivarfs`.
This fixes #38477 since it ensures the presence of `efivarfs` in the
`/sys` tree, which is why the systemd-boot installation failed.
This commit is contained in:
parent
6c064e6b1f
commit
14cab1ac57
@ -51,8 +51,9 @@ if [[ ! -e $mountPoint/etc/NIXOS ]]; then
|
||||
exit 126
|
||||
fi
|
||||
|
||||
mkdir -m 0755 -p "$mountPoint/dev"
|
||||
mkdir -m 0755 -p "$mountPoint/dev" "$mountPoint/sys"
|
||||
mount --rbind /dev "$mountPoint/dev"
|
||||
mount --rbind /sys "$mountPoint/sys"
|
||||
|
||||
# Run the activation script. Set $LOCALE_ARCHIVE to supress some Perl locale warnings.
|
||||
LOCALE_ARCHIVE=$system/sw/lib/locale/locale-archive chroot "$mountPoint" "$system/activate" >&2 || true
|
||||
|
Loading…
Reference in New Issue
Block a user