summary refs log tree commit diff
path: root/nixos/modules/system/boot
diff options
context:
space:
mode:
authorTethys Svensson <freaken@freaken.dk>2020-09-10 20:10:30 +0200
committerTethys Svensson <freaken@freaken.dk>2020-09-10 20:56:04 +0200
commitb32701bc5404ae37cfa01429962588b833913d7d (patch)
tree0a79100dc00d0b79e5deb5dbc93fb880c218b1b4 /nixos/modules/system/boot
parent20e90aac2e5ce9b44398faaf5cc971e4d09d305a (diff)
downloadnixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar.gz
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar.bz2
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar.lz
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar.xz
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.tar.zst
nixpkgs-b32701bc5404ae37cfa01429962588b833913d7d.zip
nixos/systemd-boot: Temporarily ignore errors
This is a temporary fix for #97433. A more proper fix has been
implemented upstream in systemd/systemd#17001, however until it gets
backported, we are stuck with ignoring the error.

After the backport lands, this commit should be reverted.
Diffstat (limited to 'nixos/modules/system/boot')
-rw-r--r--nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py b/nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py
index 97e824fe629..65c7b825f85 100644
--- a/nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py
+++ b/nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py
@@ -200,7 +200,9 @@ def main():
     else:
         # Update bootloader to latest if needed
         systemd_version = subprocess.check_output(["@systemd@/bin/bootctl", "--version"], universal_newlines=True).split()[1]
-        sdboot_status = subprocess.check_output(["@systemd@/bin/bootctl", "--path=@efiSysMountPoint@", "status"], universal_newlines=True)
+        # Ideally this should use check_output as well, but as a temporary
+        # work-around for #97433 we ignore any errors.
+        sdboot_status = subprocess.run(["@systemd@/bin/bootctl", "--path=@efiSysMountPoint@", "status"], universal_newlines=True, stdout=subprocess.PIPE).stdout
 
         # See status_binaries() in systemd bootctl.c for code which generates this
         m = re.search("^\W+File:.*/EFI/(BOOT|systemd)/.*\.efi \(systemd-boot (\d+)\)$",