{"action":"closed","issue":{"url":"https://api.github.com/repos/docker/docker/issues/18181","labels_url":"https://api.github.com/repos/docker/docker/issues/18181/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/18181/comments","events_url":"https://api.github.com/repos/docker/docker/issues/18181/events","html_url":"https://github.com/docker/docker/issues/18181","id":118515812,"number":18181,"title":"Filtered list images API doesn't work with registry port","user":{"login":"RickyCook","id":2114019,"avatar_url":"https://avatars.githubusercontent.com/u/2114019?v=3","gravatar_id":"","url":"https://api.github.com/users/RickyCook","html_url":"https://github.com/RickyCook","followers_url":"https://api.github.com/users/RickyCook/followers","following_url":"https://api.github.com/users/RickyCook/following{/other_user}","gists_url":"https://api.github.com/users/RickyCook/gists{/gist_id}","starred_url":"https://api.github.com/users/RickyCook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RickyCook/subscriptions","organizations_url":"https://api.github.com/users/RickyCook/orgs","repos_url":"https://api.github.com/users/RickyCook/repos","events_url":"https://api.github.com/users/RickyCook/events{/privacy}","received_events_url":"https://api.github.com/users/RickyCook/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/docker/docker/labels/status/claimed","name":"status/claimed","color":"fef2c0"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-24T01:55:38Z","updated_at":"2015-11-25T15:14:09Z","closed_at":"2015-11-25T15:14:09Z","body":"**Description of problem:**\r\nThe [list images API](http://docs.docker.com/engine/reference/api/docker_remote_api_v1.21/#list-images) seems to not work when adding the `filter` parameter that includes a registry with a port.\r\n\r\n\r\n**`docker version`:**\r\n```\r\nClient:\r\n Version:      1.9.0\r\n API version:  1.21\r\n Go version:   go1.5.1\r\n Git commit:   76d6bc9\r\n Built:        Tue Nov  3 21:18:00 UTC 2015\r\n OS/Arch:      darwin/amd64\r\n\r\nServer:\r\n Version:      1.9.0\r\n API version:  1.21\r\n Go version:   go1.4.3\r\n Git commit:   76d6bc9\r\n Built:        Tue Nov  3 19:20:09 UTC 2015\r\n OS/Arch:      linux/amd64\r\n```\r\n\r\n\r\n**`docker info`:**\r\n```\r\nContainers: 3\r\nImages: 275\r\nServer Version: 1.9.0\r\nStorage Driver: aufs\r\n Root Dir: /mnt/sda1/var/lib/docker/aufs\r\n Backing Filesystem: extfs\r\n Dirs: 291\r\n Dirperm1 Supported: true\r\nExecution Driver: native-0.2\r\nLogging Driver: json-file\r\nKernel Version: 4.1.12-boot2docker\r\nOperating System: Boot2Docker 1.9.0 (TCL 6.4); master : 16e4a2a - Tue Nov  3 19:49:22 UTC 2015\r\nCPUs: 1\r\nTotal Memory: 996.1 MiB\r\nName: dockci\r\nID: DAXI:SNXH:NRG3:2ZHQ:KO6R:6BPW:KNLU:QZ74:TRU7:46DS:YRPU:NAMK\r\nDebug mode (server): true\r\n File Descriptors: 32\r\n Goroutines: 66\r\n System Time: 2015-11-23T12:36:51.105258529Z\r\n EventsListeners: 0\r\n Init SHA1:\r\n Init Path: /usr/local/bin/docker\r\n Docker Root Dir: /mnt/sda1/var/lib/docker\r\nUsername: thatpanda\r\nRegistry: https://index.docker.io/v1/\r\nLabels:\r\n provider=vmwarefusion\r\n```\r\n\r\n\r\n**`uname -a`:**\r\n```\r\nDarwin Rickys-MacBook-Pro.local 15.0.0 Darwin Kernel Version 15.0.0: Wed Oct 28 11:41:13 PDT 2015; root:xnu-3248.20.42~5/RELEASE_X86_64 x86_64\r\n```\r\n```\r\nLinux dockci 4.1.12-boot2docker #1 SMP Tue Nov 3 06:03:36 UTC 2015 x86_64 GNU/Linux\r\n```\r\n\r\n\r\n**Environment details (AWS, VirtualBox, physical, etc.):**\r\nDocker Machine with VMWare Fusion provider running on OSX El Capitan\r\n\r\n\r\n**How reproducible:**\r\n100%, across docker CLI, docker-py, and raw HTTP\r\n\r\n\r\n**Steps to Reproduce:**\r\n- Dockerfile containing:\r\n```\r\nFROM scratch\r\nADD Dockerfile /\r\n```\r\n\r\n- `docker build -t just-built .`\r\n- `docker tag just-built:latest localhost:5000/just-built:latest`\r\n- `docker images`\r\n```\r\nREPOSITORY                          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE\r\nlocalhost:5000/just-built           latest              a5e832e1966b        13 hours ago        30 B\r\njust-built                          latest              a5e832e1966b        13 hours ago        30 B\r\n[ ... removed more images ... ]\r\n```\r\n\r\n- `docker images just-built`\r\n```\r\nREPOSITORY          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE\r\njust-built          latest              a5e832e1966b        13 hours ago        30 B\r\n```\r\n\r\n- `docker images 'localhost:5000/just-built'`\r\n```\r\nREPOSITORY          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE\r\n```\r\n\r\n_From here on is just more examples_\r\n\r\n**Using raw HTTP**\r\n\r\n- `http --verify no --cert $DOCKER_CERT_PATH/cert.pem --cert-key $DOCKER_CERT_PATH/key.pem \"https://$(docker-machine ip $(docker-machine active)):2376/images/json?filter=just-built\"` (where the `http` command is HTTPie)\r\n```\r\nHTTP/1.1 200 OK\r\nContent-Length: 202\r\nContent-Type: application/json\r\nDate: Tue, 24 Nov 2015 01:46:54 GMT\r\nServer: Docker/1.9.0 (linux)\r\n\r\n[\r\n    {\r\n        \"Created\": 1448281661,\r\n        \"Id\": \"a5e832e1966bad9ca5821738ff70f37d737ec79779c98fe36ef477ad603d8c9d\",\r\n        \"Labels\": null,\r\n        \"ParentId\": \"\",\r\n        \"RepoDigests\": [],\r\n        \"RepoTags\": [\r\n            \"just-built:latest\"\r\n        ],\r\n        \"Size\": 30,\r\n        \"VirtualSize\": 30\r\n    }\r\n]\r\n```\r\n- _no escape_ `http --verify no --cert $DOCKER_CERT_PATH/cert.pem --cert-key $DOCKER_CERT_PATH/key.pem \"https://$(docker-machine ip $(docker-machine active)):2376/images/json?filter=localhost:5000/just-built\"`\r\n- _: escaped_ `http --verify no --cert $DOCKER_CERT_PATH/cert.pem --cert-key $DOCKER_CERT_PATH/key.pem \"https://$(docker-machine ip $(docker-machine active)):2376/images/json?filter=localhost%3A5000/just-built\"`\r\n- _: and / escaped_ `http --verify no --cert $DOCKER_CERT_PATH/cert.pem --cert-key $DOCKER_CERT_PATH/key.pem \"https://$(docker-machine ip $(docker-machine active)):2376/images/json?filter=localhost%3A5000%2Fjust-built\"`\r\n```\r\nHTTP/1.1 200 OK\r\nContent-Length: 3\r\nContent-Type: application/json\r\nDate: Tue, 24 Nov 2015 01:48:08 GMT\r\nServer: Docker/1.9.0 (linux)\r\n\r\n[]\r\n```\r\n\r\n**Using docker-py**\r\n\r\n- `python -c 'import docker; k = docker.utils.kwargs_from_env(); k[\"tls\"].assert_hostname = False; c = docker.Client(**k); import pprint; pprint.pprint(c.images(name=\"just-built\"))'`\r\n```\r\n[{'Created': 1448281661,\r\n  'Id': 'a5e832e1966bad9ca5821738ff70f37d737ec79779c98fe36ef477ad603d8c9d',\r\n  'Labels': None,\r\n  'ParentId': '',\r\n  'RepoDigests': [],\r\n  'RepoTags': ['just-built:latest'],\r\n  'Size': 30,\r\n  'VirtualSize': 30}]\r\n```\r\n\r\n- ` python -c 'import docker; k = docker.utils.kwargs_from_env(); k[\"tls\"].assert_hostname = False; c = docker.Client(**k); import pprint; pprint.pprint(c.images(name=\"localhost:5000/just-built\"))'`\r\n```\r\n[]\r\n```\r\n\r\n\r\n**Actual Results:**\r\nNo results returned for `localhost:5000/just-built`, where results returned for `just-built`\r\n\r\n\r\n**Expected Results:**\r\nExactly the same results returned for `localhost:5000/just-built`, as results returned for `just-built`"}}