K8s Image Pull from Private Artifactory K8s Image Pull from Private Artifactory kubernetes kubernetes

K8s Image Pull from Private Artifactory


Are you using port, docker path, or reverse proxy configuration in Artifactory?

Validate first on another machine you can pull the image.

i.e. (docker path)

docker login ${ARTIFACTORY_URL}docker pull ${ARTIFACTORY_URL}/repo/image:tag

I believe you may be using a reverse proxy config given the naming convention:

"repo:buildversion"

In this scenario you need to do a docker login to the repo:

docker login repodocker push repo:buildversion

What this means for k8s is you likely used the wrong docker-server URL and this is why authentication won't work even with a valid API key.

If you are using reverse proxy try this:

kubectl create secret docker-registry mycred \  --docker-server=repo \  --docker-username=<your-name> \  --docker-password=<your-api-key> \  --docker-email=<your-email>