wacik93
wacik93

Reputation: 293

Docker private registry issue

I run private registry on UBUNTU 14.04:

docker run -d -p 5000:5000 registry

The proces appeard on my docker proces list. I wrote command : curl my-external-ip and I got this:

"\"docker-registry server\""

THE PROBLEM IS that when I try to push image on localhost it works fine, but after I want to push to external ip (It must be available for for more people) I got this:

The push refers to a repository [MY-EXTERNAL-IP:5000/hello] (len: 1) unable to ping registry endpoint https://MY-EXTERNAL-IP:5000/v0/ v2 ping attempt failed with error: Get https://MY-EXTERNAL-IP:5000/v2/: EOF v1 ping attempt failed with error: Get ht*ps://MY-EXTERNAL-IP:5000/v1/_ping: EOF

I am using proxy at my company, but I added export http_proxy, https_proxy, ftp_proxy to my docker file and --insecure-registry.

Upvotes: 4

Views: 3168

Answers (2)

SunghoMoon
SunghoMoon

Reputation: 1461

It looks that your docker daemon can't access docker registry(your-external-ip) through https protocol(usually it uses 443 port). Maybe you can check it first.

But with insecure mode, the network occured on http protocol. So you can tell you docker daemon to trust insecure-registry.

Try to run docker daemon with --insecure-registry="YOUR_EXTERNAL_IP"

Upvotes: 1

Vitaly Isaev
Vitaly Isaev

Reputation: 5815

It seems like your Docker daemon still doesn't understand that registry on your $EXTERNAL_IP should be accessed over HTTP rather than HTTPS. You need to be sure that daemon runs with the --insecure-registry $EXTERNAL_IP option:

ps aux | grep docker

If you'll not be able to find it there, you probably made a mistake in your DOCKER_OPTIONS.

Upvotes: 0

Related Questions