From 33e94c46f32fb2e9b1f7106d7a790f074815dfd1 Mon Sep 17 00:00:00 2001 From: Serge Schneider Date: Thu, 11 Oct 2018 16:39:39 +0100 Subject: [PATCH] stage2: set timezone properly --- stage2/01-sys-tweaks/00-debconf | 2 -- stage2/03-set-timezone/02-run.sh | 8 ++++++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100755 stage2/03-set-timezone/02-run.sh diff --git a/stage2/01-sys-tweaks/00-debconf b/stage2/01-sys-tweaks/00-debconf index 35839c3..96aa9b0 100644 --- a/stage2/01-sys-tweaks/00-debconf +++ b/stage2/01-sys-tweaks/00-debconf @@ -7,8 +7,6 @@ console-setup console-setup/codeset47 select Guess optimal character set # Font for the console: # Choices: Fixed, Goha, GohaClassic, Terminus, TerminusBold, TerminusBoldVGA, VGA, Do not change the boot/kernel font, Let the system select a suitable font console-setup console-setup/fontface47 select Do not change the boot/kernel font -tzdata tzdata/Areas select Europe -tzdata tzdata/Zones/Europe select London # Key to function as AltGr: # Choices: The default for the keyboard layout, No AltGr key, Right Alt (AltGr), Right Control, Right Logo key, Menu key, Left Alt, Left Logo key, Keypad Enter key, Both Logo keys, Both Alt keys keyboard-configuration keyboard-configuration/altgr select The default for the keyboard layout diff --git a/stage2/03-set-timezone/02-run.sh b/stage2/03-set-timezone/02-run.sh new file mode 100755 index 0000000..67cbfd3 --- /dev/null +++ b/stage2/03-set-timezone/02-run.sh @@ -0,0 +1,8 @@ +#!/bin/bash -e + +echo "Europe/London" > "${ROOTFS_DIR}/etc/timezone" +rm "${ROOTFS_DIR}/etc/localtime" + +on_chroot << EOF +dpkg-reconfigure -f noninteractive tzdata +EOF