On 04/10/2023 14:05, Stoiko Ivanov wrote:
> diff --git a/src/proxmox-boot/zz-proxmox-boot 
> b/src/proxmox-boot/zz-proxmox-boot
> index 1adc1b1..0d08dbf 100755
> --- a/src/proxmox-boot/zz-proxmox-boot
> +++ b/src/proxmox-boot/zz-proxmox-boot
> @@ -215,6 +215,23 @@ disable_systemd_boot_hook() {
>  
>  }
>  
> +check_grub_efi_package() {
> +
> +     if [ -f "${ESP_LIST}" ]; then
> +             return
> +     fi
> +
> +     if [ ! -d /sys/firmware/efi ]; then
> +             return
> +     fi
> +
> +     if [ ! -f /usr/share/doc/grub-efi-amd64/changelog.Debian.gz ]; then
> +             return
> +     fi

If I understand correctly, this check needs to be inverted, since we do
want to warn if grub-efi-amd64 is *not* installed? (only noticed because
my UEFI-based test machine did not print the warning below on upgrade)

> +     warn "uefi-booted system, without grub-efi-amd64 package - /boot/efi 
> will not be updated"
> +
> +}
> +
>  set -- $DEB_MAINT_PARAMS
>  mode="${1#\'}"
>  mode="${mode%\'}"
> @@ -228,6 +245,7 @@ case $0:$mode in
>               BOOT_KVERS="$(boot_kernel_list "$@")"
>               update_esps
>               disable_systemd_boot_hook
> +             check_grub_efi_package
>       ;;
>        */postrm.d/*:|*/postrm.d/*:remove)
>               reexec_in_mountns "$@"
> @@ -235,6 +253,7 @@ case $0:$mode in
>               BOOT_KVERS="$(boot_kernel_list)"
>               update_esps
>               disable_systemd_boot_hook
> +             check_grub_efi_package
>       ;;
>  esac
>  


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to