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

DockerHub as a src registry #9

Closed
bartsmykla opened this issue Feb 19, 2019 · 9 comments
Closed

DockerHub as a src registry #9

bartsmykla opened this issue Feb 19, 2019 · 9 comments
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@bartsmykla
Copy link

After doing some research about how time consuming would be to implement DockerHub as a src registry I think there are three paths we can take.

  1. Current implementation use gcloud CLI tool for work related registries, so we could create a simple, similar CLI tool with the same API related to commands we need (I think it's the quickest way)
  2. Create an abstraction just for DockerHub without using any CLI tool, where it would coexist with current implementation for GCR (GCR would use gcloud tool and DockerHub would send direct requests to its REST API) [quite time consuming].
  3. Create an abstraction from the ground up which will be communicating with any Docker Container Registry via REST API (it's the most time-consuming option, because we have to figure out how to handle different ways of auth and I assume your decision of use gcloud instead of just calling API was due of that)

I looked into: https://github.com/google/go-containerregistry which would be a nice tool to use, but there are no features related to registry like listing of repositories etc., so there would be need to implement them.

It would be good to talk about it, because maybe there are other ways I couldn't see. Irrespective of decision I would love to implement the changes. :-)

Bart

@listx
Copy link
Contributor

listx commented Feb 19, 2019

First, thank you so much for looking into this area. I agree with your 3 paths you outlined.

The main reason I chose to use gcloud was because it allowed me to ignore everything related to authentication (I just assume that the service account specified in the promoter manifest is already authenticated), because I wanted to get this tool out and working asap.

You are right that the go-containerregistry doesn't really support the features we need (esp. regarding manifest lists, as I stated in #7).

I think (1) will add unnecessary complexity (we would now need 2 tools...?). IMHO (2) is the best choice for now. At some point down the road, I'm sure we would move away from gcloud as well and just use pure REST calls directly as it is cleaner (no need to worry about spawning another process and hook up the stdout pipes to it and such). The other issue with gcloud I noticed is that it prints informational messages to stderr, which is a little bit confusing.

Going with (3) would be even better, but I agree that it would be time consuming. Although, to be fair, with #7 we still need to use REST calls anyway (or at least move to using curl instead of gcloud).

@listx listx added the kind/feature Categorizes issue or PR as related to a new feature. label Feb 22, 2019
@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 23, 2019
@listx
Copy link
Contributor

listx commented May 24, 2019

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 24, 2019
@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Aug 22, 2019
@listx
Copy link
Contributor

listx commented Aug 26, 2019

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Aug 26, 2019
@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Nov 24, 2019
@fejta-bot
Copy link

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Dec 24, 2019
@fejta-bot
Copy link

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

@k8s-ci-robot
Copy link
Contributor

@fejta-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests

4 participants