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
Support private repo #41
Conversation
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
e7f830b
to
a83a9b2
Compare
@@ -41,3 +41,7 @@ | |||
[[constraint]] | |||
name = "github.com/openfaas/faas-provider" | |||
version = "0.14.0" | |||
|
|||
[[constraint]] | |||
name = "github.com/docker/cli" |
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.
When I looked at the containerd resolve it seemed cleaner / more lightweight without depending on Docker itself, like this - https://github.com/containerd/containerd/blob/master/cmd/ctr/commands/resolver.go
Do you think it can be made to work without the Docker CLI?
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.
like "github.com/containerd/containerd/remotes/docker" using NewDockerAuthorizer?
Even it (https://github.com/containerd/containerd/blob/4f348c5b5b53a70b282ab5b81b2cc8f03bf6a338/remotes/docker/authorizer.go#L90) didn't seem to use Docker itself.
What do you think?
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.
We can't easily remove dependency on docker/cli, mostly because I believe we want to support cred helper binaries, though I think I've heard that there is an alternative go pkg for that.
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.
Maybe we should open docker/cli PR to reduce dependencies
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.
Is this needed to support the helper binaries then? Does containerd/cri not support pulling from AWS ECR then?
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.
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.
I wonder what @ibuildthecloud did in k3c? https://github.com/rancher/k3c/blob/master/pkg/daemon/image.go
I can see a reference to docker/distribution there actually
Let's go for it, thank you for this PR 👍 If we find a way to remove Docker for auth later on, it can be changed again. |
Description
Support private repo with the credential located as
/var/lib/faasd/.docker/config.json
.Motivation and Context
#30
I haveAlex has raised an issue to propose this change this is requiredHow Has This Been Tested?
Tested using a private Docker Hub repo.
Types of changes
Checklist:
Commits:
git commit -s
for the Developer Certificate of Origin (DCO)Code:
Docs: