From: Jóhann B. Guðmundsson Date: Thu, 22 Apr 2021 11:04:24 +0000 (+0000) Subject: feat(systemd-network-management): introducing systemd-network-management module X-Git-Tag: 054~86 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e942d86c9ddad19f9307d58cb2d99169f6e94edb;p=thirdparty%2Fdracut.git feat(systemd-network-management): introducing systemd-network-management module Introducing the systemd-network-management meta module which will allow distribution users and vendors to easily include systemd + systemd's network management modules by simply include this module instead of systemd network modules individually. Obviously if the intent is to glue together somekind of network stack out of random existing modules such as NetworkManager and or Wicked, this meta module should not be enabled. --- diff --git a/dracut.spec b/dracut.spec index 4603eb853..5612561da 100644 --- a/dracut.spec +++ b/dracut.spec @@ -316,6 +316,7 @@ echo 'dracut_rescue_image="yes"' > $RPM_BUILD_ROOT%{dracutlibdir}/dracut.conf.d/ %endif %{dracutlibdir}/modules.d/00bash %{dracutlibdir}/modules.d/00systemd +%{dracutlibdir}/modules.d/00systemd-network-management %ifnarch s390 s390x %{dracutlibdir}/modules.d/00warpclock %endif diff --git a/modules.d/00systemd-network-management/module-setup.sh b/modules.d/00systemd-network-management/module-setup.sh new file mode 100755 index 000000000..f8ba35180 --- /dev/null +++ b/modules.d/00systemd-network-management/module-setup.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# This file is part of dracut. +# SPDX-License-Identifier: GPL-2.0-or-later + +# Prerequisite check(s) for module. +check() { + + # 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 systemd-hostnamed systemd-networkd systemd-resolved systemd-timedated systemd-timesyncd + # Return 0 to include the dependent module(s) in the initramfs. + return 0 + +}