Skip to content
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

Remove replication of proxy project #15155

Closed
govindkailas opened this issue Jun 17, 2021 · 3 comments · Fixed by #16286
Closed

Remove replication of proxy project #15155

govindkailas opened this issue Jun 17, 2021 · 3 comments · Fixed by #16286

Comments

@govindkailas
Copy link

We enable replication from our Harbor primary site to DR site. Something that we notice is whenever it reaches the proxy projects the replications are failing with the below error,
http status code: 403, body: {"errors":[{"code":"DENIED","message":"denied: can not push artifact to a proxy project: dockerhub-proxy-cache"}]}

If this is by design, please consider skipping proxy project from replication.

@stonezdj
Copy link
Contributor

stonezdj commented Nov 9, 2021

It is possible to exclude the proxy cache project when pulling images to a remote, we could check the current project is proxy cache project.

@stonezdj
Copy link
Contributor

stonezdj commented Dec 23, 2021

Create proxy cache project dockhub_proxy in server A and B. and setup an event-based replication, it seems that this error can not reproduce now.
When caching an image in A/dockerhub_proxy/library/hello-world:latest , it trigger a replication job which replicate the image to A/dockerhub_proxy/library/hello-world:latest to B/dockerhub_proxy/library/hello-world:latest.
Before replication, server A check if the artifact exists in the remote registry, it sends a HEAD request the server B. check if the B/dockerhub_proxy/library/hello-world:latest exist, because B/dockerhub_proxy is a proxy-cache project, it proxy the request to dockerhub and HTTP 200 to the server A eventually, then server A consider this image already exists in server B. and mark this replication job succeed.

It is better to solve this issue in replication, but it seems not urgent.

@pjastrzabek
Copy link

Before 2.5.x versions we had a working helm charts replication into proxy project.

That harbor project had 2 functions:

  • it was a proxy project for docker images
  • and was holding replicated helm charts

After update to 2.5.x helm chart replication (explicitly selected in replication rule) does not work (All created replication tasks are skipped with a log "skip create replication task because of dest limitation")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment