[pve-devel] [PATCH installer 3/3] set the keymap on the installer console

Stoiko Ivanov s.ivanov at proxmox.com
Tue Nov 10 15:15:30 CET 2020


this patch partially reverts 8bc528041ba85e1b9bd4c17638a2302088bc19ce
by writing /etc/default/keyboard and running `setupcon` in the background
the delay should not harm the UX in the installer

Signed-off-by: Stoiko Ivanov <s.ivanov at proxmox.com>
---
 proxinstall | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/proxinstall b/proxinstall
index 1551e18..2bc30e8 100755
--- a/proxinstall
+++ b/proxinstall
@@ -2784,6 +2784,18 @@ sub create_country_view {
 
 	    if (! $opt_testmode) {
 		syscmd ("setxkbmap $xkmap $xvar");
+
+		my $kbd_config = qq{
+		    XKBLAYOUT="$xkmap"
+		    XKBVARIANT="$xvar"
+		    BACKSPACE="guess"
+		};
+		$kbd_config =~ s/^\s+//gm;
+
+		run_in_background( sub {
+		    write_config($kbd_config, '/etc/default/keyboard');
+		    system("setupcon");
+		});
 	    }
 	}
     });
-- 
2.20.1






More information about the pve-devel mailing list