Skip to content

Commit 279e3b0

Browse files
committed
fix: build host setup script adjusted for limited resource ubuntu vagrant VMs
on ubuntu-20 vagrant VMs the /boot partition is too small to handle the updates to kernel initrd images and such so we run autoremove and try upgrade again. Ticket: ENT-13854 Changelog: none
1 parent 8f0abe9 commit 279e3b0

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

ci/setup-cfengine-build-host.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,12 @@ if [ -f /etc/os-release ]; then
8686
yum update --assumeyes
8787
alias software='yum install --assumeyes'
8888
elif grep -q debian /etc/os-release; then
89-
DEBIAN_FRONTEND=noninteractive apt upgrade --yes && DEBIAN_FRONTEND=noninteractive apt autoremove --yes
89+
# sometimes the /boot partition is too small to handle kernel upgrade regenerations of initrd and related files on ubuntu, so allow failure first
90+
DEBIAN_FRONTEND=noninteractive apt upgrade --yes || true
91+
DEBIAN_FRONTEND=noninteractive apt autoremove --yes
92+
# and now perform the upgrade a second time after hopefully autoremove cleans up /boot partition of kernel files that cause failure
93+
DEBIAN_FRONTEND=noninteractive apt upgrade --yes
94+
DEBIAN_FRONTEND=noninteractive apt autoremove --yes
9095
alias software='DEBIAN_FRONTEND=noninteractive apt install --yes'
9196
elif grep -q suse /etc/os-release; then
9297
zypper -n update

0 commit comments

Comments
 (0)