feat: graceful fallback for apt-get update failures (#12386)

Add apt_update_safe() function that warns instead of aborting when apt-get update fails (e.g. enterprise repo 401 Unauthorized). Shows a helpful hint about disabling the enterprise repo when no subscription is active. Replaces direct  apt-get update calls in build.func and install.func.
This commit is contained in:
CanbiZ (MickLesk)
2026-02-27 14:39:39 +01:00
committed by GitHub
parent 9e9dfd6947
commit a2dc3f44d3
3 changed files with 50 additions and 2 deletions

View File

@@ -233,7 +233,7 @@ fi
EOF
chmod +x /usr/local/bin/apt-proxy-detect.sh
fi
$STD apt-get update
apt_update_safe
$STD apt-get -o Dpkg::Options::="--force-confold" -y dist-upgrade
rm -rf /usr/lib/python3.*/EXTERNALLY-MANAGED
msg_ok "Updated Container OS"