From 48db35cc76439dafc43f3654ff8771cfae0cff3d Mon Sep 17 00:00:00 2001 From: oddlama Date: Thu, 26 Nov 2020 13:29:47 +0100 Subject: [PATCH] Actually select keymap and timezone on systemd configurations. Fixes #4. --- scripts/main.sh | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/scripts/main.sh b/scripts/main.sh index c3cc0b7..1d1e8a3 100755 --- a/scripts/main.sh +++ b/scripts/main.sh @@ -64,12 +64,23 @@ configure_base_system() { # Set hostname einfo "Selecting hostname" - echo "$HOSTNAME" > /etc/hostname + echo "$HOSTNAME" > /etc/hostname \ + || die "Could not write /etc/hostname" + + # Set keymap + einfo "Selecting keymap" + echo "KEYMAP=$KEYMAP" > /etc/vconsole.conf \ + || die "Could not write /etc/vconsole.conf" + + einfo "Selecting timezone" + ln -sfn "../usr/share/zoneinfo/$TIMEZONE" /etc/localtime \ + || die "Could not change /etc/localtime link" + + # TODO use systemd-nspawn to start instead of chroot, then we can use these utils. #hostnamectl set-hostname "$HOSTNAME" \ # || die "Could not set hostname" ## Set timezone - # TODO use systemd-nspawn to start instead of chroot, then we can use these utils. #einfo "Selecting timezone" #timedatectl set-timezone "$TIMEZONE" \ # || die "Could not set timezone"