Skip to content

Update CI image + purge python-gnupg + 3.115 compatibility#1481

Open
dralley wants to merge 6 commits into
pulp:mainfrom
dralley:centos-ci
Open

Update CI image + purge python-gnupg + 3.115 compatibility#1481
dralley wants to merge 6 commits into
pulp:mainfrom
dralley:centos-ci

Conversation

@dralley

@dralley dralley commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

No description provided.

jobselko
jobselko previously approved these changes Jul 21, 2026
@dralley
dralley requested a review from mdellweg July 21, 2026 23:44
@dralley dralley changed the title Switch to the newer CentOS Stream 10 CI base image Update CI image + purge python-gnupg Jul 21, 2026
@dralley

dralley commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

python-gnupg is finicky against newer versions of GPG, and it was breaking with the CentOS Stream 10 image, so I'm just going to take this opportunity to replace it with pysequoia, which I needed to do anyway as part of the PQC work.

And to get it working with 3.115 there are some small changes required.

@dralley dralley changed the title Update CI image + purge python-gnupg Update CI image + purge python-gnupg + 3.115 compatibility Jul 21, 2026
return _deb_copy_content_domain


def import_signing_key(key_url, gpg_home):

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This block copied straight from pulpcore. We could import from pulpcore, but I figured it's easier to just keep them independent, and we're deleting enough code that I don't feel bad about it.

@dralley
dralley force-pushed the centos-ci branch 3 times, most recently from bc5a186 to d3ef28c Compare July 22, 2026 01:51
@dralley
dralley requested a review from quba42 July 22, 2026 13:22
@dralley

dralley commented Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

@quba42 Matthias suggested I ask for your review also given the changes. Overall it's a significant simplification since sequoia doesn't require all of the ceremony that gnupg does, setting up a one-off gnupghome and then needing to clean it up after, etc.

pulpbot and others added 6 commits July 22, 2026 09:27
python-gnupg wraps the gpg binary and is sensitive to GnuPG version
differences. The switch to CentOS 10 (GnuPG 2.4) broke things.

Replace all runtime uses of python-gnupg with pysequoia via pulpcore's
gpg_verify() helper.

This has other benefits - support for newer PGP certificates and
standards (including PQC) and no reliance on a system CLI tool that
needs to be shelled out to and cleaned up after.

- signing_service.py: remove prepare_gpg(), use gpg_verify() for all
  signature verification in AptReleaseSigningService and
  AptPackageSigningService
- synchronizing.py: remove _gpg_agent_cleanup decorator and GPG instance
  management, use gpg_verify() directly in verify_gpg_artifacts()
- signing.py: replace gpg --list-packets subprocess call with
  pysequoia PacketPile for extracting issuer key IDs from _gpgorigin

Assisted-By: Claude Opus 4.6
Replace the signing_gpg_metadata and signing_gpg_extra fixtures with
deb_signing_key_primary and deb_signing_key_secondary, which return
GPGKeyInfo dataclass instances instead of gnupg.GPG objects.

Copy the import_signing_key, create_signing_service, and
remove_signing_service helper functions from pulpcore and use them to
simplify local test fixtures

Add python-gnupg to functest_requirements.txt since it is still used.

Assisted-By: Claude Opus 4.6
Use find_api_root(lstrip=True) instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants