Repository navigation
Let CI give up on an apt mirror that hangs - #20
Merged
Merged
Conversation
Both `sudo apt-get update` calls on the runner (the test workflow's tools step and the release workflow's Packages step) now go through tools/apt-update.sh, the same file as in Cron Jobs: it sets apt's download timeouts and retries for the rest of the job and gives the update 150 seconds and three tries.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Every
sudo apt-get updateon the runner waits for the Ubuntu mirror until the job's time limit runs out when the mirror stops answering. On 2026-10-31 and 2026-11-01 that cancelled single jobs in Azentrius/cockpit-update-gaps, Azentrius/cockpit-host-settings and Azentrius/cockpit-image-update-monitor after 15 to 20 minutes without any output, while their sibling jobs finished the same step in seconds.tools/apt-update.shis the same file the add-ons use since Azentrius/cockpit-cronjobs#78 (blob383c97c, executable):Acquire::http::Timeout "20",Acquire::https::Timeout "20"andAcquire::Retries "3"to/etc/apt/apt.conf.d/99-ci-timeouts, so they also apply to theapt-get installthat follows.apt-get update -qq150 seconds and three tries, 15 seconds apart. Each failed try gets a warning, and the step fails only after the third.Both runner calls now use it: the tools step in
test.ymland the Packages step inrelease.yml. Both run after the checkout, in the repository root. Theapt-getcalls inside the Debian container of the repository test stay as they are: the script is not there, and they go to Debian's mirror and the local test repository.make lintchecks the script with shellcheck. CI on this pull request runs the changed test step; the release step is the same two lines.