0

When I try to push an image like

docker push jikuma/dockercomposetest

it is resolved as

docker.io/jikuma/dockercomposetest repository url.

I want to use v2 docker hub registry url. How can I do that. What should be my registry url. And how to make it default for docker client?

Here is docer version output.

Client: 
  Version:      17.06.0-ce     
  API version:  1.30  
  Go version:   go1.8.3    
  Git commit:   02c1d87
  Built:        Fri Jun 23 21:30:30 2017
  OS/Arch:      windows/amd64

Server:
  Version:      17.06.0-ce
  API version:  1.30 (minimum version 1.12)
  Go version:   go1.8.3
  Git commit:   02c1d87
  Built:        Fri Jun 23 21:51:55 2017
  OS/Arch:      linux/amd64
  Experimental: true
Gryu
  • 2,102
  • 2
  • 16
  • 29
Jitendra
  • 732
  • 1
  • 9
  • 29
  • What version of docker? – Tarun Lalwani Aug 17 '17 at 20:19
  • Client: Version: 17.06.0-ce API version: 1.30 Go version: go1.8.3 Git commit: 02c1d87 Built: Fri Jun 23 21:30:30 2017 OS/Arch: windows/amd64 Server: Version: 17.06.0-ce API version: 1.30 (minimum version 1.12) Go version: go1.8.3 Git commit: 02c1d87 Built: Fri Jun 23 21:51:55 2017 OS/Arch: linux/amd64 Experimental: true – Jitendra Aug 18 '17 at 07:17
  • Are you not able to pull or push images? – Tarun Lalwani Aug 18 '17 at 07:18
  • There is a `--disable-legacy-registry Disable contacting legacy registries (default true)` in `/etc/docker/daemon.json` (https://docs.docker.com/engine/reference/commandline/dockerd/) – Tarun Lalwani Aug 18 '17 at 07:20
  • Here is my docker deamon configuration. { "registry-mirrors": [], "insecure-registries": [], "debug": true, "experimental": true, "disable-legacy-registry": true } . Still when i do docker login i get v1 registry url on config.json { "auths": { "https://index.docker.io/v1/": {} }, "credsStore": "wincred" }. I am using windows docker client and deamon. – Jitendra Aug 18 '17 at 07:29
  • You are using Docker toolbox or Docker for windows? – Tarun Lalwani Aug 18 '17 at 07:39
  • Docker for Windows. And now i have observed same behaviour in linux. – Jitendra Aug 18 '17 at 07:42
  • Seem like it. The behavior is consistent across all platforms "https://index.docker.io/v1/". The auth might be happen on this url and pull on a `v2` because the pulls happen on `registry-1.docker.io/v2` – Tarun Lalwani Aug 18 '17 at 08:07

0 Answers0