Skip to content

Fix APT mirror transport URI handling - #17

Merged
Bpoe merged 2 commits into
mainfrom
fix/apt-repository-transports
Oct 27, 2026
Merged

Bpoe merged 2 commits into
mainfrom
fix/apt-repository-transports

Conversation

@Bpoe

@Bpoe Bpoe commented Oct 27, 2026

Copy link
Copy Markdown
Owner

Debian 13 cloud images use mirror+file:///etc/apt/mirrors/debian.list and debian-security.list. dscpm aptRepositories export rejected these URIs, and its shared identity helper appended a misleading / to mirror-list filenames in diagnostics.

Extend the shared APT validator to support mirror, mirror+http, mirror+https, mirror+file, and mirror+copy, plus local copy repositories. Validate network and local transports according to their URI shape while retaining credential and fragment restrictions. Compare mirror-list URIs exactly and preserve their original spelling without resolving mirror lists or normalizing paths. All CLI operations and both DSC manifests use the same implementation.

Regression tests cover Debian mirror lists, Ubuntu HTTP/HTTPS sources, local repositories, both APT source formats, URI round trips, unsafe URIs, and Export → compliant Test through the CLI and DSC.

Validation after rebasing onto main (b7d9d75):

  • DSCPM_REQUIRE_DSC=1 go test ./... -skip '^TestDSCPackagesIntegration$' -count=1 in resources/package-management: passed, using Go 1.25.0 and DSC 3.3.0.
  • git diff --check upstream/main: passed.
  • The full suite was also run. The existing TestDSCPackagesIntegration fails because it combines stderr with JSON stdout and this machine's DSC emits a startup warning about /etc/dsc permissions. All other tests pass, including the new DSC URI integration tests.

@Bpoe
Bpoe merged commit fc407a5 into main Oct 27, 2026
16 checks passed
@Bpoe
Bpoe deleted the fix/apt-repository-transports branch October 27, 2026 20:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant