-
Notifications
You must be signed in to change notification settings - Fork 5k
Add Google Artifact Registry adapter with OAuth2 authentication #22429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
4040a78
to
a86f7c3
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #22429 +/- ##
==========================================
+ Coverage 45.36% 46.67% +1.30%
==========================================
Files 244 252 +8
Lines 13333 14255 +922
Branches 2719 2927 +208
==========================================
+ Hits 6049 6653 +604
- Misses 6983 7246 +263
- Partials 301 356 +55
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a needed addition...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds Google Artifact Registry (GAR) adapter with OAuth2 authentication support to Harbor's registry replication system. The adapter extends Harbor's capability to proxy/replicate from Google's newer GAR service alongside the existing GCR support.
- Implements OAuth2 authentication for Google Artifact Registry
- Adds comprehensive adapter implementation with proper endpoint patterns
- Updates UI and configuration to include GAR in supported registry types
Reviewed Changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
src/portal/src/i18n/lang/en-us-lang.json | Updates tooltip text to include Google GAR in supported proxy cache registries |
src/portal/src/app/base/project/project-config/project-policy-config/project-policy-config.component.ts | Adds google-gar to supported registry type query string |
src/portal/src/app/base/left-side-nav/projects/create-project/create-project.component.ts | Adds google-gar to supported registry type query string |
src/pkg/reg/model/registry.go | Defines RegistryTypeGoogleGar constant |
src/pkg/reg/manager.go | Registers the Google GAR adapter import |
src/pkg/reg/adapter/googlegar/auth/* | Implements OAuth2 authentication with comprehensive test coverage |
src/pkg/reg/adapter/googlegar/adapter* | Core GAR adapter implementation with registry pattern definitions |
src/pkg/chart/testdata/harbor-schema*/templates/core/core-cm.yaml | Updates permitted registry types to include google-gar |
src/jobservice/job/impl/replication/replication.go | Imports the googlegar adapter for job service usage |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Signed-off-by: Strainy <[email protected]>
Head branch was pushed to by a user without write access
a86f7c3
to
8268f2b
Compare
Thanks for your contribution, could you please demo this adapter in our community meeting? if you could add a CI to verify the GAR adapter would be appreciated. |
I'm quite pressed for time at the moment, so won't be able to do this.
I've added unit tests. Is there something else I need to do to "add a CI"? Maybe an example is in order 🙏 |
Comprehensive Summary of your change
This change adds a new adapter for Google Artifact Registry. We've been using Google ADC (via Workload Identity Federation) in combination with this adapter for a number of months. All working well.
Issue being fixed
Fixes #20682
Please indicate you've done the following: