From 1250dc6a1d4fe1dbb8bcd21fc642c4ffdc60e0c7 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 18 Jul 2024 12:47:51 +0200 Subject: [PATCH 1/5] mkosi: Fix formatting All of our lists start on the next line, so let's make KernelCommandLine= fit that as well. --- mkosi.conf | 47 ++++++++++++++++++++++++----------------------- 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/mkosi.conf b/mkosi.conf index 56a89e8c22..78dbc33c70 100644 --- a/mkosi.conf +++ b/mkosi.conf @@ -56,29 +56,30 @@ SELinuxRelabel=no # Adding more kernel command line arguments is likely to hit the kernel command line limit (512 bytes) in # various scenarios. Consider adding support for a credential instead if possible and using that. -KernelCommandLine=systemd.crash_shell - systemd.log_level=debug,console:info - systemd.log_ratelimit_kmsg=0 - # Disable the kernel's ratelimiting on userspace logging to kmsg. - printk.devkmsg=on - # Make sure /sysroot is mounted rw in the initrd. - rw - # Lower the default device timeout so we get a shell earlier if the root device does - # not appear for some reason. - systemd.default_device_timeout_sec=30 - # Make sure no LSMs are enabled by default. - selinux=0 - systemd.early_core_pattern=/core - systemd.firstboot=no - raid=noautodetect - oops=panic - panic=-1 - softlockup_panic=1 - panic_on_warn=1 - # These don't ship proper units with [Install] directives so we have to mask them instead. - systemd.mask=isc-dhcp-server.service - systemd.mask=mdmonitor.service - psi=1 +KernelCommandLine= + systemd.crash_shell + systemd.log_level=debug,console:info + systemd.log_ratelimit_kmsg=0 + # Disable the kernel's ratelimiting on userspace logging to kmsg. + printk.devkmsg=on + # Make sure /sysroot is mounted rw in the initrd. + rw + # Lower the default device timeout so we get a shell earlier if the root device does + # not appear for some reason. + systemd.default_device_timeout_sec=30 + # Make sure no LSMs are enabled by default. + selinux=0 + systemd.early_core_pattern=/core + systemd.firstboot=no + raid=noautodetect + oops=panic + panic=-1 + softlockup_panic=1 + panic_on_warn=1 + # These don't ship proper units with [Install] directives so we have to mask them instead. + systemd.mask=isc-dhcp-server.service + systemd.mask=mdmonitor.service + psi=1 KernelModulesInitrdExclude=.* KernelModulesInitrdInclude=default From 1d914b268c116f5491f02bb554e45483404ed82a Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 18 Jul 2024 12:48:48 +0200 Subject: [PATCH 2/5] mkosi: Drop udev from Packages= list It's pulled in via VolatilePackages=, no need to put it in Packages=. --- mkosi.conf | 1 - 1 file changed, 1 deletion(-) diff --git a/mkosi.conf b/mkosi.conf index 78dbc33c70..a628f96d25 100644 --- a/mkosi.conf +++ b/mkosi.conf @@ -125,7 +125,6 @@ Packages= tar tmux tree - udev util-linux valgrind which From 91cc65c5ad6135f428cd6500d19268581ece70b2 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 18 Jul 2024 12:51:44 +0200 Subject: [PATCH 3/5] mkosi: Drop util-linux from centos/fedora packages It's already included in the packages list in mkosi.conf. --- mkosi.conf.d/10-centos-fedora/mkosi.conf | 1 - 1 file changed, 1 deletion(-) diff --git a/mkosi.conf.d/10-centos-fedora/mkosi.conf b/mkosi.conf.d/10-centos-fedora/mkosi.conf index 6083fe4f07..5b1865a253 100644 --- a/mkosi.conf.d/10-centos-fedora/mkosi.conf +++ b/mkosi.conf.d/10-centos-fedora/mkosi.conf @@ -56,6 +56,5 @@ Packages= squashfs-tools stress-ng tpm2-tools - util-linux veritysetup vim-common From ac31804db7b679ae4a4ea028642b87e528ed3a6b Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 18 Jul 2024 12:53:53 +0200 Subject: [PATCH 4/5] mkosi: Fix typo Our config parsing is flexible enough that this kind of worked surprisingly enough. --- mkosi.conf.d/10-centos/mkosi.conf | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/mkosi.conf.d/10-centos/mkosi.conf b/mkosi.conf.d/10-centos/mkosi.conf index c9c570375d..d97b08138e 100644 --- a/mkosi.conf.d/10-centos/mkosi.conf +++ b/mkosi.conf.d/10-centos/mkosi.conf @@ -8,13 +8,12 @@ Release=10 [Content] Environment= - Environment= - # We'd prefer to use XFS here but it fails to mount on duplicate filesystem UUIDs which - # happens when running tests in parallel so we use ext4 instead. - SYSTEMD_REPART_OVERRIDE_FSTYPE_ROOT=ext4 - # The kernel versions in CentOS Stream 9 doesn't support orphan_file, but later versions of - # mkfs.ext4 enabled it by default, so we disable it explicitly. - SYSTEMD_REPART_MKFS_OPTIONS_EXT4="-O ^orphan_file" + # We'd prefer to use XFS here but it fails to mount on duplicate filesystem UUIDs which + # happens when running tests in parallel so we use ext4 instead. + SYSTEMD_REPART_OVERRIDE_FSTYPE_ROOT=ext4 + # The kernel versions in CentOS Stream 9 doesn't support orphan_file, but later versions of + # mkfs.ext4 enabled it by default, so we disable it explicitly. + SYSTEMD_REPART_MKFS_OPTIONS_EXT4="-O ^orphan_file" Packages= kernel-modules # For squashfs From 2315c6996f198b44034fab7a02dc4b8a21c13248 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 18 Jul 2024 13:01:27 +0200 Subject: [PATCH 5/5] mkosi: Fix indentation --- mkosi.images/initrd/mkosi.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mkosi.images/initrd/mkosi.conf b/mkosi.images/initrd/mkosi.conf index ab5be9b884..3f2c5c77ce 100644 --- a/mkosi.images/initrd/mkosi.conf +++ b/mkosi.images/initrd/mkosi.conf @@ -7,8 +7,8 @@ Include= [Content] ExtraTrees= - %D/mkosi.leak-sanitizer-suppressions:/usr/lib/systemd/leak-sanitizer-suppressions - %D/mkosi.coredump-journal-storage.conf:/usr/lib/systemd/coredump.conf.d/10-coredump-journal-storage.conf + %D/mkosi.leak-sanitizer-suppressions:/usr/lib/systemd/leak-sanitizer-suppressions + %D/mkosi.coredump-journal-storage.conf:/usr/lib/systemd/coredump.conf.d/10-coredump-journal-storage.conf Packages= findutils