Checks whether $rootfs is ZFS and adds "keymap" to $initfs_features.
This is required for encrypted ZFS installations that prompt for a
passphrase at boot to ensure that the appropriate keymap is used for
non-US keyboard users.
ref: https://gitlab.alpinelinux.org/alpine/aports/-/issues/13291
Signed-off-by: Edin Taric <unicorn@regrow.earth>
---
setup-disk.in | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/setup-disk.in b/setup-disk.in
index 58ea7c8..df760ab 100644
--- a/setup-disk.in
+++ b/setup-disk.in
@@ -492,6 +492,10 @@ install_mounted_root() {
root_fs=$(find_mount_fs "$mnt")
initfs_features="$initfs_features $root_fs"
+ if [ "$rootfs" = "zfs" ]; then
+ initfs_features="$initfs_features keymap"
+ fi
+
if is_lvm "$rootdev"; then
initfs_features="$initfs_features lvm"
local vg=$(find_volume_group "$rootdev")
--
2.34.1