-
Notifications
You must be signed in to change notification settings - Fork 141
composefs-native/boot: Handle systemd-boot and grub #1571
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
composefs-native/boot: Handle systemd-boot and grub #1571
Conversation
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.
Code Review
This pull request introduces support for both systemd-boot
and grub
by adding a --bootloader
option, which is a great enhancement. The changes are well-structured, particularly the use of the BLSEntryPath
struct to handle bootloader-specific paths. I've identified a critical issue with temporary directory handling that could lead to resource leaks, and a high-severity issue regarding backward compatibility for existing deployments. Addressing these will make the implementation more robust.
f0e8700
to
6362c43
Compare
fd703ec
to
023be10
Compare
0838456
to
fa58def
Compare
Fix Grub boot error caused by bootc-dev#1541. Introduce a `--bootloader` cli option to `--composefs-native`. Depending upon the type of bootloader passed in we write BLS configs respectively Signed-off-by: Pragyan Poudyal <pragyanpoudyal41999@gmail.com> Add guard again tempdir drop Signed-off-by: Pragyan Poudyal <pragyanpoudyal41999@gmail.com>
fa58def
to
31934ae
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.
LGTM as is however...I still think we should detect grub instead via looking for its config files
Is there some peculiar reason why we should be looking for grub config files? I think the EFI vars approach is a bit better as it also lets us distinguish BIOS/UEFI |
In theory we should work with any bootloader that implements the spec instead of specifically detecting systemd-boot - right? |
Right. AFAIK bootloaders on UEFI will populate the LoaderInfo file with the bootloader name, which we check right now. Though, we do default to Grub if we can't find |
Fix Grub boot error caused by #1541. Introduce a
--bootloader
cli option to--composefs-native
. Depending upon the type of bootloader passed in we write BLS configs respectively