New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos/systemd-boot: update bootloader if needed #90386
Conversation
78ddb79
to
10a662f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small nits, but apart from that, tested and LGTM.
nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py
Outdated
Show resolved
Hide resolved
nixos/modules/system/boot/loader/systemd-boot/systemd-boot-builder.py
Outdated
Show resolved
Hide resolved
systemd/systemd@6cd12eb changed behaviour - now the "default" entry needs to identity an entry with its full name, including the ".conf". Reported-In: NixOS#86422
10a662f
to
42b9225
Compare
Thanks! |
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) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line fails on my system, because of Boot into FW: not supported
, which causes the entire command to fail, when then causes check_output
to throw an exception. Is that the expected behavior in this case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ignore this comment, I submitted an issue about this instead.
Motivation for this change
Fixes #86422
Messing with people's existing bootloaders is always a little scary, so I'd appreciate a careful review.
Tested with
Also tested on my own physical machine.
CC @flokli @Mic92
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)