pve-kernel-meta/debian
Stoiko Ivanov 3a982230c1 proxmox-boot: maintscript: change logic whether to add diversion
Deciding whether or not to add the diversion based on the version
alone fails quite hard in case pve-kernel-helper is in dpkg-state 'rc'
(removed not purged) as reported in our community forum[0]:
* removing pve-kernel-helper removes the diversion of grub-install
* if config-files are still present the preinst script gets called
  with the version of the config-files (the version that got removed)
* if the version was newer than 6.4-1~ then no diversion is added
* unpacking fails, because grub-install would be overwritten leaving
  pve-kernel-helper in state 'ic'

Explicitly checking whether the diversion is in place sounds like a
robust approach here.

downside: documentation on dpkg-divert in maintainer scripts [1] uses
the version approach.

[0] https://forum.proxmox.com/threads/pve-kernel-helper-wont-install.90029/
[1] https://www.debian.org/doc/debian-policy/ap-pkg-diversions.html

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2021-07-08 08:44:35 +02:00
..
changelog bump version to 7.0-3 2021-06-23 10:58:57 +02:00
compat d/control: bump debhelper compat to >= 12 2021-05-12 17:28:38 +02:00
control.in d/control: bump debhelper compat to >= 12 2021-05-12 17:28:38 +02:00
copyright initial commit 2018-03-06 09:16:31 +01:00
postinst.in initial commit 2018-03-06 09:16:31 +01:00
postrm.in initial commit 2018-03-06 09:16:31 +01:00
pve-kernel-helper.install proxmox-boot: add grub-install wrapper 2021-04-23 13:28:56 +02:00
pve-kernel-helper.links proxmox-boot-tool: rename from pve-efiboot-tool 2021-04-23 13:28:56 +02:00
pve-kernel-helper.maintscript d/maintscripts: we will use 6.4-1 as next version 2021-04-23 13:28:56 +02:00
pve-kernel-helper.postinst proxmox-boot: rename uuid list file 2021-04-23 13:28:56 +02:00
pve-kernel-helper.postrm d/postrm: use correct version for check 2021-04-23 13:28:56 +02:00
pve-kernel-helper.preinst proxmox-boot: maintscript: change logic whether to add diversion 2021-07-08 08:44:35 +02:00
rules pve-kernel-helper: add new package 2019-07-10 20:17:53 +02:00