From: Laszlo Gombos Date: Sun, 14 Apr 2024 18:21:23 +0000 (-0400) Subject: feat(systemd-bsod): dracut module for systemd-bsod X-Git-Tag: 102~118 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d7ab919eaa6d820545ca73549e1ce87f8c00aefb;p=thirdparty%2Fdracut-ng.git feat(systemd-bsod): dracut module for systemd-bsod --- diff --git a/modules.d/01systemd-bsod/module-setup.sh b/modules.d/01systemd-bsod/module-setup.sh new file mode 100755 index 000000000..91b28d7f4 --- /dev/null +++ b/modules.d/01systemd-bsod/module-setup.sh @@ -0,0 +1,30 @@ +#!/bin/bash +# This file is part of dracut. +# SPDX-License-Identifier: GPL-2.0-or-later + +# Prerequisite check(s) for module. +check() { + # If the binary(s) requirements are not fulfilled the module can't be installed + require_binaries "$systemdutildir"/systemd-bsod || return 1 + + # Return 255 to only include the module, if another module requires it. + return 255 +} + +# Module dependency requirements. +depends() { + # This module has external dependency on other module(s). + echo systemd-journald + # Return 0 to include the dependent module(s) in the initramfs. + return 0 +} + +# Install the required file(s) for the module in the initramfs. +install() { + inst_multiple \ + "$systemdsystemunitdir"/systemd-bsod.service \ + "$systemdsystemunitdir"/initrd.target.wants/systemd-bsod.service \ + "$systemdutildir"/systemd-bsod + + inst_libdir_file "libqrencode.so*" +} diff --git a/test/container/Dockerfile-Arch b/test/container/Dockerfile-Arch index 2cf7b757b..78bbc916a 100644 --- a/test/container/Dockerfile-Arch +++ b/test/container/Dockerfile-Arch @@ -37,6 +37,7 @@ RUN pacman --noconfirm -Syu \ pigz \ plymouth \ qemu \ + qrencode \ rng-tools \ sbsigntools \ shellcheck \ diff --git a/test/container/Dockerfile-Fedora-latest b/test/container/Dockerfile-Fedora-latest index 8279a8c02..137f412ce 100644 --- a/test/container/Dockerfile-Fedora-latest +++ b/test/container/Dockerfile-Fedora-latest @@ -3,6 +3,7 @@ FROM registry.fedoraproject.org/fedora:latest # Install needed packages for the dracut CI container RUN dnf -y install --setopt=install_weak_deps=False \ asciidoc \ + astyle \ bash-completion \ biosdevname \ bluez \ @@ -27,6 +28,7 @@ RUN dnf -y install --setopt=install_weak_deps=False \ iproute \ iputils \ iscsi-initiator-utils \ + jq \ kbd \ kernel \ kmod-devel \ @@ -49,6 +51,7 @@ RUN dnf -y install --setopt=install_weak_deps=False \ pcsc-lite \ pigz \ qemu-system-x86-core \ + qrencode \ rng-tools \ rpm-build \ sbsigntools \