Repository navigation
Conversation
reset_sources.sh downloads key 871920D1991BC93C from keyserver.ubuntu.com and writes "gpg --export" of it over /etc/apt/trusted.gpg.d/ubuntu-keyring-2018-archive.gpg. It does not check either command. When the keyserver cannot be reached, gpg exports nothing, the key file the image shipped is replaced with an empty one, the script exits 0, and the next "apt-get update" fails for every line of sources.list: gpg: keyserver receive failed: Connection refused gpg: WARNING: nothing exported NO_PUBKEY 871920D1991BC93C E: The repository 'http://archive.ubuntu.com/ubuntu resolute-security InRelease' is not signed. This failed the "Build & Test rtp.io module (Quick)" job on 2026-11-11. The Ubuntu image already has the key, in that file and in /usr/share/keyrings/ubuntu-archive-keyring.gpg. Use the copy the image has, and ask the keyserver only when there is none. In that case retry five times, check that the export holds the key before installing it, and exit non-zero when it cannot be had, so the job stops at the step that failed.
Member
Author
|
Closing: the keyserver is reachable again and the rtp.io job passes without this change. |
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.
Summary
scripts/build/reset_sources.shreplaces the Ubuntu archive key that the build image ships with an empty file wheneverkeyserver.ubuntu.comcannot be reached, and exits 0. The nextapt-get updatethen fails withNO_PUBKEY 871920D1991BC93C. This patch uses the key the image already has and asks the keyserver only when the image has none.Details
The script runs:
Neither command is checked. In the
Build & Test rtp.io module (Quick)job of run 43072186355 (2026-11-11, on #4442) and run 43068444793 (another pull request, the same day) the log shows:The
sippylabs/rtpproxy:latestimage (Ubuntu resolute) already has that key in/etc/apt/trusted.gpg.d/ubuntu-keyring-2018-archive.gpg(1167 bytes) and in/usr/share/keyrings/ubuntu-archive-keyring.gpg. The failed download overwrote the first with a 0-byte file.Solution
Testing
Run in the arm64 build of
sippylabs/rtpproxy:latest, with the workflow'sInstall gitstep first andkeyserver.ubuntu.compointed at 127.0.0.1 to block it. The amd64 image the workflow uses was not run locally; this pull request's ownrtp.iorun covers it.NO_PUBKEY(6 lines) andis not signed(3 lines)NO_PUBKEYNO_PUBKEYCompatibility
The script is used only by
.github/workflows/rtp.io.yml. On an image without the Ubuntu keyring (thebookwormbranch of the script) the keyserver path is still taken, now with retries and a non-zero exit on failure.