Skip to content

Fix ORAS repo auth#1131

Open
isc-dchui wants to merge 4 commits intomainfrom
fix-oras-auth
Open

Fix ORAS repo auth#1131
isc-dchui wants to merge 4 commits intomainfrom
fix-oras-auth

Conversation

@isc-dchui
Copy link
Copy Markdown
Collaborator

Description

  • Fixes Unable to connect to Github Container Registry #1130
  • Addresses a few gaps in the ORAS repo implementation:
    • Fixes the auth flow for checking availability of repository
    • Repo URL no longer requires scheme since the default is often scheme-less, e.g. ghcr.io vs https://ghcr.io
    • Adds an "Authenticated?" line to the repo display for ORAS repos
    • Adds implementation of bearer token exchange for probing of credentials because the ORAS library does not support timeouts

Testing

Tested this manually:
First created a PAT with appropriate scopes (https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry).
Then configured using this IPM line: repo -o -n github -url ghcr.io -namespace <GitHub-username> -username <GitHub-username> -password <PAT>.
Was able to install and publish modules to and from the repo.

Added some unit tests and removed the redundant preexisting test because 1) it's an integration test not a unit test, and 2) everything it tests is already covered elsewhere.

Checklist

  • This branch has the latest changes from the main branch rebased or merged.
  • Changelog entry added.
  • Unit (zpm test -only) and integration tests (zpm verify -only) pass.
  • Style matches the style guide in the contributing guide.
  • Documentation has been/will be updated
    • I'll add an extra section to the wiki
  • Pull request correctly renders in the "Preview" tab.

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.

Unable to connect to Github Container Registry

1 participant