ctr does not read /etc/containerd/config.toml credential settings when pulling images from ghcr.io #6539
-
DescriptionI added ghcr.io private registry auth config to
And restart containerd
And check containerd config settings whether it was updated (printing my ghcr.io settings)
Steps to reproduce the issueNo response Describe the results you received and expectedProblem is here when i pull some images from my github organization package registry, ghcr.io returns 401 error
I think Is this bug? What version of containerd are you using?containerd github.com/containerd/containerd 1.5.9+bottlerocket 1407cab Any other relevant informationNo response Show configuration if it is related to CRI plugin.No response |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 6 replies
-
ctr does not use CRI API, so it does not read any configuration from If you want to debug the CRI config, you have to use crictl. If you aren't interested in CRI and you just want to run a containerd container with GHCR, you can just use containerd/cmd/ctr/commands/commands.go Line 64 in 0340e84 See also |
Beta Was this translation helpful? Give feedback.
-
That solve me problem too. |
Beta Was this translation helpful? Give feedback.
-
I just spent half a day trying to figure out why the docs on how to configure a registry mirror for containerd apparently weren't working. I don't think most would expect that this CLI and Kubernetes would be so divergent. I expected that I could use What's the reasoning for having |
Beta Was this translation helpful? Give feedback.
ctr does not use CRI API, so it does not read any configuration from
[plugins."io.containerd.grpc.v1.cri"]
.If you want to debug the CRI config, you have to use crictl.
If you aren't interested in CRI and you just want to run a containerd container with GHCR, you can just use
ctr --user USER:PASS
:containerd/cmd/ctr/commands/commands.go
Line 64 in 0340e84
See also
nerdctl
: https://github.com/containerd/nerdctl/blob/master/docs/registry.md#github-container-registry-ghcr