From 5551746088633116a28f3ded9d7003f378b6cd17 Mon Sep 17 00:00:00 2001 From: Jo Zzsi Date: Sat, 24 Aug 2024 20:23:14 -0400 Subject: [PATCH] fix(systemd): systemd-vconsole-setup has a dependency on loadkeys loadkeys is installed by 10i18n dracut module. --- modules.d/00systemd/module-setup.sh | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/modules.d/00systemd/module-setup.sh b/modules.d/00systemd/module-setup.sh index 2eecc6fd6..237ad7ff7 100755 --- a/modules.d/00systemd/module-setup.sh +++ b/modules.d/00systemd/module-setup.sh @@ -36,7 +36,6 @@ install() { "$systemdutildir"/systemd-shutdown \ "$systemdutildir"/systemd-reply-password \ "$systemdutildir"/systemd-fsck \ - "$systemdutildir"/systemd-vconsole-setup \ "$systemdutildir"/systemd-volatile-root \ "$systemdutildir"/systemd-sysroot-fstab-check \ "$systemdutildir"/system-generators/systemd-debug-generator \ @@ -79,7 +78,6 @@ install() { "$systemdsystemunitdir"/systemd-reboot.service \ "$systemdsystemunitdir"/systemd-kexec.service \ "$systemdsystemunitdir"/systemd-fsck@.service \ - "$systemdsystemunitdir"/systemd-vconsole-setup.service \ "$systemdsystemunitdir"/systemd-volatile-root.service \ "$systemdsystemunitdir"/ctrl-alt-del.target \ "$systemdsystemunitdir"/syslog.socket \ @@ -154,14 +152,18 @@ EOF 90-vconsole.rules \ 99-systemd.rules - for i in \ - emergency.target \ - rescue.target; do - [[ -f "$systemdsystemunitdir"/$i ]] || continue - if [ -e "$systemdsystemunitdir"/systemd-vconsole-setup.service ]; then + if dracut_module_included "10i18n" && [[ -e "$systemdsystemunitdir"/systemd-vconsole-setup.service ]]; then + inst_multiple -o \ + "$systemdutildir"/systemd-vconsole-setup \ + "$systemdsystemunitdir"/systemd-vconsole-setup.service + + for i in \ + emergency.target \ + rescue.target; do + [[ -f "$systemdsystemunitdir"/$i ]] || continue $SYSTEMCTL -q --root "$initdir" add-wants "$i" systemd-vconsole-setup.service - fi - done + done + fi mkdir -p "$initdir/etc/systemd"