]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Do not try to copy vmlinuz for non-bootable images
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 13 Oct 2023 15:12:25 +0000 (17:12 +0200)
committerJörg Behrmann <behrmann@physik.fu-berlin.de>
Fri, 13 Oct 2023 19:17:20 +0000 (21:17 +0200)
When building an initrd, copy_vmlinuz() would fail because there is
no vmlinuz file to copy.

mkosi/__init__.py

index a52961e975bb50e121014b241beb34c91014a377..ec9275a524f00394d30b720c141844f7b6e2a41b 100644 (file)
@@ -1353,6 +1353,9 @@ def copy_nspawn_settings(state: MkosiState) -> None:
 
 
 def copy_vmlinuz(state: MkosiState) -> None:
+    if state.config.bootable == ConfigFeature.disabled:
+        return
+
     if (state.staging / state.config.output_split_kernel).exists():
         return