Not able to push docker images to docker private registry - docker

I have created docker private register in my local "10.234.1.254"
If i tag an image as 10.234.1.254:5000/hello-world and try to push it from another vm to the vm where registry is running - IT FAILS with below error
The push refers to a repository [10.234.1.254:5000/hello-world]
unable to ping registry endpoint https://10.234.1.254:5000/v0/
v2 ping attempt failed with error: Get https://10.234.1.254:5000/v2/: EOF
v1 ping attempt failed with error: Get https://10.234.1.254:5000/v1/_ping: EOF
I even tried putting DOCKER_OPTS="--insecure-registry 10.234.1.254:5000" in /etc/default/docker and restart docker service. But still i get the same error.
How do i tag an image using IP address and port of the private docker registry and push it?

met the same issue at macOSX, the docker version is:
➜ registry docker version
Client:
Version: 17.11.0-ce-rc4
API version: 1.34
Go version: go1.8.4
Git commit: 587f1f0
Built: Thu Nov 16 01:17:06 2017
OS/Arch: darwin/amd64
Server:
Version: 17.11.0-ce-rc4
API version: 1.34 (minimum version 1.12)
Go version: go1.8.5
Git commit: 587f1f0
Built: Thu Nov 16 01:43:23 2017
OS/Arch: linux/amd64
Experimental: true
➜ registry docker push 10.168.32.26:5000/metric-collector:dev
The push refers to repository [10.168.32.26:5000/metric-collector]
Get http://10.168.32.26:5000/v2/: EOF
➜ registry curl http://10.168.32.26:5000/v2/
curl: (52) Empty reply from server
➜ registry docker login 10.168.32.26:5000
Username: 1
Password:
Error response from daemon: Get http://10.168.32.26:5000/v2/: EOF

Related

docker version calling wrong ip address

when I write docker version in cmd I get this error.
error during connect: Get "http://127.0.0.1:12375/v1.24/version": dial tcp 127.0.0.1:12375: connectex: No connection could be made because the target machine actively refused it.
Client:
Cloud integration: 1.0.17
Version: 20.10.8
API version: 1.41
Go version: go1.16.6
Git commit: 3967b7d
Built: Fri Jul 30 19:58:50 2021
OS/Arch: windows/amd64
Context: default
Experimental: true
It is localhost:12375 instead of localhost:2375.
The docker command line uses the environment variable DOCKER_HOST to specify the url of the docker daemon to interact with. Check where you have that value set and update with the correct URL.

docker private registry change from v1 to v2 while pulling an image

There is a docker is registry v2.
An image is pushed to docker private registry. Able to see it using curl command:
$ curl -s -X GET http://<registry>:<port>/v2/<image>/tags/list
{"name":"<image>","tags":["latest"]}
However, not able to pull the image from other machines. It appears that it is trying to pull from v1 instead of v2
Pulling the above image on a windows 10 machine.
docker pull <registry>:<port>/<image>:latest
Getting the following error:
Pulling repository <registry>:<port>/<image>
Network timed out while trying to connect to
http://<registry>:<port>/v1/repositories/<image>/images.
You may want to check your internet connection or if you are behind a proxy.
Not using any proxy settings.
Here is version details
Client:
Version: 17.03.1-ce
API version: 1.27
Go version: go1.7.5
Git commit: c6d412e
Built: Tue Mar 28 00:40:02 2017
OS/Arch: windows/amd64
Server:
Version: 17.03.1-ce
API version: 1.27 (minimum version 1.12)
Go version: go1.7.5
Git commit: c6d412e
Built: Fri Mar 24 00:00:50 2017
OS/Arch: linux/amd64
Experimental: true
Could not found any docker settings for changing from v1 to v2.
How do I make it to pull from v2 / resolve the above error?
EDIT: log shows
ICMP Destination Unreachable: Destination port unreachable

Can't get Docker image after windows installation

I just installed docker on my windows 10 server,
Installation went fine but I can't seem to get images from central docker repo.
those are my specs:
c:\>docker version
Client:
Version: 1.13.0
API version: 1.25
Go version: go1.7.3
Git commit: 49bf474
Built: Wed Jan 18 16:20:26 2017
OS/Arch: windows/amd64
Server:
Version: 1.13.0
API version: 1.25 (minimum version 1.12)
Go version: go1.7.3
Git commit: 49bf474
Built: Wed Jan 18 16:20:26 2017
OS/Arch: linux/amd64
Experimental: true
This is my test command:
c:\>docker run hello-world
Unable to find image 'hello-world:latest' locally
docker: Error response from daemon: Get https://registry-1.docker.io/v2/: remote error: tls: access denied.
See 'docker run --help'.
This is what I get when running curl on that repo:
c:\>curl -k https://registry-1.docker.io/v2/
{"errors":[{"code":"UNAUTHORIZED","message":"authentication required","detail":null}]}
I guess that there is something to do with my company DNS/Network,
did anyone encounter this issue on windows?
You need to set your proxy env variables.
[Environment]::SetEnvironmentVariable("HTTP_PROXY", "http://username:password#proxy:port/", [EnvironmentVariableTarget]::Machine)
Restart-Service docker
Check this for reference: https://learn.microsoft.com/en-us/virtualization/windowscontainers/manage-docker/configure-docker-daemon
And more common:
https://docs.docker.com/engine/admin/systemd/#http-proxy
As I replied to #Falco Alexander I got some PowerShell errors, But The proxy was already set in my env. variables.
What finally did the trick was to set the proxy inside the docker GUI:
And then restart the service.

docker Connection refused

I have running docker and when want to send request from docker to my rails server
i have got
curl localhost:3000
curl: (7) Failed connect to localhost:3000; Connection refused
but my rails server has been started.
docker version
Client:
Version: 1.9.1
API version: 1.21
Go version: go1.4.3
Git commit: a34a1d5
Built: Fri Nov 20 17:56:04 UTC 2015
OS/Arch: darwin/amd64
Server:
Version: 1.12.3
API version: 1.24
Go version: go1.6.3
Git commit: 6b644ec
Built: 2016-10-26T23:26:11.105168198+00:00
OS/Arch: linux/amd64
i have started docker with eval "$(docker-machine env default)"
upd My rails server outside docker container
As I see you use docker-machine so you have to use the docker-machine IP and not localhost. To get docker-machine IP, use docker-machine ip command.

Docker Compose (docker-compose) couldn't connect to docker daemon on Windows Server 2016 TP5

I am trying to get docker-compose to work on Windows Server 2016 TP5. I have installed Docker Desktop for Windows (not Docker Toolbox) as a service, which works perfectly. I have downloaded the latest docker-compose for windows from https://dl.bintray.com/docker-compose/master/ and put it in the same path as Docker (after unblocking the downloaded file, and renaming it to docker-compose.exe.
When I run the docker-compose up (in Powershell as an Administrator), I get the following error:
ERROR: Couldn't connect to Docker daemon. You might need to install
Docker:
https://docs.docker.com/engine/installation/
Here are the docker and docker-compose information on my machine:
Docker:
Client:
Version: 1.12.1
API version: 1.24
Go version: go1.6.3
Git commit: 23cf638
Built: Thu Aug 18 17:52:38 2016
OS/Arch: windows/amd64
Server:
Version: 1.12.1
API version: 1.24
Go version: go1.6.3
Git commit: 23cf638
Built: Thu Aug 18 17:52:38 2016
OS/Arch: windows/amd64
Docker Compose:
docker-compose version 1.9.0dev, build f65f89a
You might want to try to set your DOCKER_HOST:
$ENV:DOCKER_HOST="npipe://\\.\pipe\docker_engine"
Alternatively, when registering the engine, you can make it listen on TCP too:
dockerd.exe -H npipe:////./pipe/docker_engine -H localhost:2375 --register-service
There are more details on this Compose issue

Resources