Generate a GRUB config if is not present in the ESP

If there's no GRUB config in the ESP, generate one. This is a full config
but later the posttrans script will convert it to the minimal config stub.

Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
This commit is contained in:
Javier Martinez Canillas 2021-06-11 00:18:35 +02:00
parent 6b5d11f760
commit 6dc8b4a57a
No known key found for this signature in database
GPG Key ID: C751E590D63F3D69

View File

@ -354,7 +354,7 @@ EFI_HOME=%{efi_esp_dir}
GRUB_HOME=/boot/grub2
if test ! -f ${EFI_HOME}/grub.cfg; then
exit 0 # nothing to unify, nothing to do
grub2-mkconfig -o ${EFI_HOME}/grub.cfg
fi
if grep -q "configfile" ${EFI_HOME}/grub.cfg; then