I loaded a Docker image to my K3 cluster like so:
# ctr -n k8s.io -a /run/k3s/containerd/containerd.sock image import /home/rocky/myawx-v1.0.0.tar
(actually I have tried many different version of the above command)
I can see the image here:
# k3s ctr image ls | grep awx
docker.io/library/myawx:v1.0.0 application/vnd.docker.distribution.manifest.v2+json sha256:7...9 617.3 MiB linux/amd64 io.cri-containerd.image=managed
quay.io/ansible/awx-ee:latest application/vnd.docker.distribution.manifest.v2+json sha256:5...0 613.4 MiB linux/amd64 io.cri-containerd.image=managed
quay.io/ansible/awx-ee@sha256:5...0 application/vnd.docker.distribution.manifest.v2+json sha256:5...0 613.4 MiB linux/amd64 io.cri-containerd.image=managed```
But if I try to pull the image I get this error:
# k3s ctr image pull docker.io/library/myawx:v1.0.0
docker.io/library/myawx:v1.0.0: resolving |--------------------------------------|
elapsed: 0.5 s total: 0.0 B (0.0 B/s)
INFO[0000] trying next host error="pull access denied, repository does not exist or may require authorization: server message:
insufficient_scope: authorization failed" host=registry-1.docker.io
ctr: failed to resolve reference "docker.io/library/myawx:v1.0.0": pull access denied,
repository does not exist or may require authorization: server message:
insufficient_scope: authorization failed
If I try to run the image I get this ...
# k3s ctr run docker.io/library/myawx myawx-run
ctr: image "docker.io/library/myawx": not found
I have no idea what I am doing and I am just grasping at straws.
k3s ctr image ls | grep awx
simply tells you that the image is loaded locally (not to the registry).
In the next command when you do a k3s ctr image pull..
or k3s ctr image run
, you're actually expecting the image to be pulled down from the remote registry.
Which registry are you trying to pull this from?
docker.io/library/myawx:v1.0.0
to me looks like it's going to the docker registry and not to the registry you want it to.