diff mbox series

[1/6] scripts/bringup_guestfs.sh: uninstall unattended-upgrades on debian guests

Message ID 20250323115009.269172-2-mcgrof@kernel.org (mailing list archive)
State New
Headers show
Series debian / libvirt / devconfig fixes | expand

Checks

Context Check Description
mcgrof/vmtest-main-VM_Test-7 success Logs for Setup and Run Make Targets (opensuse/tumbleweed)
mcgrof/vmtest-main-VM_Test-5 success Logs for Setup and Run Make Targets (fedora:latest)
mcgrof/vmtest-main-VM_Test-6 success Logs for Setup and Run Make Targets (opensuse/tumbleweed)
mcgrof/vmtest-main-VM_Test-4 success Logs for Setup and Run Make Targets (fedora:latest)
mcgrof/vmtest-main-VM_Test-3 success Logs for Setup and Run Make Targets (debian:testing)
mcgrof/vmtest-main-VM_Test-2 success Logs for Setup and Run Make Targets (debian:testing)
mcgrof/vmtest-main-PR fail PR summary
mcgrof/vmtest-main-VM_Test-1 fail Logs for Run kdevops CI
mcgrof/vmtest-main-VM_Test-0 fail Logs for Run kdevops CI

Commit Message

Luis Chamberlain March 23, 2025, 11:50 a.m. UTC
Be sure to remove unattended-upgrades when taking the downloaded image
from Debian to build our base image which we will use to launch guests
with.

The package unattended-upgrades [0] is one of the biggest pain points
for continous integeration on kdevops, where we race against package
installations being mucked behind our back. So let's just be
extremely vocal about it being a requirement to not be installed
on debian systems and complain and ensure systems don't have it.

Even though we have already in place devconfig rules to remove it,
upon first bringup you can still race against it!

If you do have an old guest with it, you should just remove the old
guest and re-do your new guest as otherwise you will encounter many
odd silly bugs and the issue is just races with debian doing its
upgrades with unattended-upgrades.

To my surprise unattended-upgrades has also been a default on debian
for years now, it would seem we can just move to a debian image of
"netinst" or "minimal" images but that requires more work than what
we can just do by removing the package.

Long term we really should request to see if is debian folks can
ends up packaging a proper guestfs image based on debian testing for us,
and when that does happen we ask it does not have unattended-upgrades.

[0] https://wiki.debian.org/UnattendedUpgrades

Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
---
 scripts/bringup_guestfs.sh | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/scripts/bringup_guestfs.sh b/scripts/bringup_guestfs.sh
index 7166842307b5..1ba2c8c6ff9a 100755
--- a/scripts/bringup_guestfs.sh
+++ b/scripts/bringup_guestfs.sh
@@ -223,6 +223,7 @@  firstboot-command systemctl stop ssh
 firstboot-command DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true dpkg-reconfigure -p low --force openssh-server
 firstboot-command systemctl start ssh
 firstboot-command apt update && apt upgrade --yes
+uninstall unattended-upgrades
 _EOT
 	# CONFIG_GUESTFS_COPY_SOURCES_FROM_HOST_TO_GUEST will not work
 	# if /etc/nsswitch.conf has a line like this: