From 19373e38f82b3d47e496bd0d87777fae30d68ba7 Mon Sep 17 00:00:00 2001 From: Javier Viguera Date: Thu, 27 Jul 2023 17:08:32 +0200 Subject: [PATCH] systemd: remove console on virtual terminals This reuses the same variable from sysvinit (USE_VT) to disable running getty/login on virtual terminals. Signed-off-by: Javier Viguera --- meta-digi-dey/recipes-core/systemd/systemd_%.bbappend | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meta-digi-dey/recipes-core/systemd/systemd_%.bbappend b/meta-digi-dey/recipes-core/systemd/systemd_%.bbappend index 55a98777e..cf8b62a96 100644 --- a/meta-digi-dey/recipes-core/systemd/systemd_%.bbappend +++ b/meta-digi-dey/recipes-core/systemd/systemd_%.bbappend @@ -20,4 +20,9 @@ do_install:append () { SUBSYSTEM=="input", KERNEL=="event[0-9]*", ENV{ID_INPUT_TOUCHSCREEN}=="1", SYMLINK+="input/touchscreen0" EOF fi + + # Disable virtual terminals + if [ "${USE_VT}" = "0" ]; then + sed -i -e "/getty@.service/s,enable,disable,g" ${D}${systemd_unitdir}/system-preset/90-systemd.preset + fi }