Unable to push to private repository from outside the registry server

I am trying to setup a private repository where I want to push both linux and windows based images. The registry setup seems to be missing something or I have not configured it properly or have the wrong version.

The registry is setup on Ubuntu1604. I can push and pull images from the server itself using the local client. However when I try to push from another machine it does not work.

These are the log messages:

Jun 08 21:13:25 ubudockerregistry docker-compose[5596]: registry_1  | time="2017-06-08T11:13:25Z" level=info msg="response completed" go.version=go1.7.3 http.request.host=192.168.0.219 http.request.id=497532dc-182a-49fa-9ef8-f24e423111b9 http.request.method=POST http.request.remoteaddr=192.168.0.200 http.request.uri="/v2/mono/blobs/uploads/" http.request.useragent="docker/17.06.0-ce-rc1 go/go1.8.1 git-commit/7f8486a kernel/4.9.30-moby os/linux arch/amd64 UpstreamClient(Docker-Client/17.06.0-ce-rc1 \\(windows\\))" http.response.duration=7.716929ms http.response.status=202 http.response.written=0 instance.id=d91cdaec-feeb-4e57-b567-50d20304cbbb version=v2.6.1
Jun 08 21:13:25 ubudockerregistry docker-compose[5596]: registry_1  | 172.17.0.3 - - [08/Jun/2017:11:13:25 +0000] "POST /v2/mono/blobs/uploads/ HTTP/1.0" 202 0 "" "docker/17.06.0-ce-rc1 go/go1.8.1 git-commit/7f8486a kernel/4.9.30-moby os/linux arch/amd64 UpstreamClient(Docker-Client/17.06.0-ce-rc1 \\(windows\\))"
Jun 08 21:13:25 ubudockerregistry docker-compose[5596]: nginx_1     | 192.168.0.4 - omc [08/Jun/2017:11:13:25 +0000] "POST /v2/mono/blobs/uploads/ HTTP/1.1" 202 0 "-" "docker/17.06.0-ce-rc1 go/go1.8.1 git-commit/7f8486a kernel/4.9.30-moby os/linux arch/amd64 UpstreamClient(Docker-Client/17.06.0-ce-rc1 \x5C(windows\x5C))" "192.168.0.200"
Jun 08 21:13:25 ubudockerregistry docker-compose[5596]: registry_1  | time="2017-06-08T11:13:25Z" level=info msg="response completed" go.version=go1.7.3 http.request.host=192.168.0.219 http.request.id=56bd4e01-e253-40c3-8432-3cf7102a9467 http.request.method=POST http.request.remoteaddr=192.168.0.200 http.request.uri="/v2/mono/blobs/uploads/" http.request.useragent="docker/17.06.0-ce-rc1 go/go1.8.1 git-commit/7f8486a kernel/4.9.30-moby os/linux arch/amd64 UpstreamClient(Docker-Client/17.06.0-ce-rc1 \\(windows\\))" http.response.duration=5.382493ms http.response.status=202 http.response.written=0 instance.id=d91cdaec-feeb-4e57-b567-50d20304cbbb version=v2.6.1
Jun 08 21:13:25 ubudockerregistry docker-compose[5596]: registry_1  | 172.17.0.3 - - [08/Jun/2017:11:13:25 +0000] "POST /v2/mono/blobs/uploads/ HTTP/1.0" 202 0 "" "docker/17.06.0-ce-rc1 go/go1.8.1 git-commit/7f8486a kernel/4.9.30-moby os/linux arch/amd64 UpstreamClient(Docker-Client/17.06.0-ce-rc1 \\(windows\\))"

This is my docker-compose file:

root@ubudockerregistry:/opt/registry# cat docker-compose.yml
nginx:
  image: nginx:1.9
  ports:
    - 80:80
  links:
    - registry:registry
  volumes:
    - ./nginx:/etc/nginx/conf.d

registry:
  image: registry:2
  ports:
    - 5000:5000
  environment:
    REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY: /data
  volumes:
    - ./data:/dataroot@ubudockerregistry:/opt/registry#

This is my NGINX config:

upstream docker-registry {
  server registry:5000;
}

server {
  listen 80;
  server_name ubudockerregistry;

  # SSL
  # ssl off;
  # ssl_certificate /etc/nginx/conf.d/domain.crt;
  # ssl_certificate_key /etc/nginx/conf.d/domain.key;

  # disable any limits to avoid HTTP 413 for large image uploads
  client_max_body_size 0;

  # required to avoid HTTP 411: see Issue #1486 (https://github.com/docker/docker/issues/1486)
  chunked_transfer_encoding on;

  location /v2/ {
    # Do not allow connections from docker 1.5 and earlier
    # docker pre-1.6.0 did not properly set the user agent on ping, catch "Go *" user agents
    if ($http_user_agent ~ "^(docker\/1\.(3|4|5(?!\.[0-9]-dev))|Go ).*$" ) {
      return 404;
    }

    # To add basic authentication to v2 use auth_basic setting plus add_header
    auth_basic "registry.localhost";
    auth_basic_user_file /etc/nginx/conf.d/registry.password;
    add_header 'Docker-Distribution-Api-Version' 'registry/2.0' always;

    proxy_pass                          http://docker-registry;
    proxy_set_header  Host              $http_host;   # required for docker client's sake
    proxy_set_header  X-Real-IP         $remote_addr; # pass on real client's IP
    proxy_set_header  X-Forwarded-For   $proxy_add_x_forwarded_for;
    proxy_set_header  X-Forwarded-Proto $scheme;
    proxy_read_timeout                  900;
  }
}

This is my docker registry server info:

root@ubudockerregistry:/opt/registry# docker info
Containers: 2
 Running: 2
 Paused: 0
 Stopped: 0
Images: 4
Server Version: 17.03.1-ce
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 22
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 4ab9917febca54791c5f071a9d1f404867857fcc
runc version: 54296cf40ad8143b62dbcaa1d90e520a2136ddfe
init version: 949e6fa
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.4.0-79-generic
Operating System: Ubuntu 16.04.2 LTS
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 3.842 GiB
Name: ubudockerregistry
ID: CWQY:EVWC:XYXA:DLOC:XN7A:YQAK:53AS:XSVD:F4W5:H44B:BS6L:4MLY
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Http Proxy: https://xxxx:3128/ (removed)
Https Proxy: https://xxxx:3128/ (removed)
No Proxy: localhost,127.0.0.1,localaddress,.localdomain.com
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

This is the docker client server info

PS C:\Users\Mihir Mone> docker info
Containers: 4
 Running: 0
 Paused: 0
 Stopped: 4
Images: 2
Server Version: 17.06.0-ce-rc1
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host ipvlan macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 3addd840653146c90a254301d6c3a663c7fd6429
runc version: 992a5be178a62e026f4069f443c6164912adbf09
init version: 949e6fa
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.9.30-moby
Operating System: Alpine Linux v3.5
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.934GiB
Name: moby
ID: OZC4:U5QS:UU4Z:BFYP:VCHM:7WHB:DN7X:VNC3:BOAL:5PNJ:J3AP:5RJK
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 24
 Goroutines: 42
 System Time: 2017-06-08T01:32:41.9345499Z
 EventsListeners: 0
Http Proxy: xxxx:3128 (removed)
Https Proxy: xxxx:3128 (removed)
Registry: https://index.docker.io/v1/
Experimental: true
Insecure Registries:
 192.168.0.219
 127.0.0.0/8
Live Restore Enabled: false

The only difference my #noob eyes see is that the registry server’s docker version is lower than the client server’s docker version.

Could really use another set of eyes!