Docker Community Forums

Share and learn in the Docker community.

Docker-compose fails with backports.ssl_match_hostname.CertificateError when connect to other host


(Otetz) #1

Expected behavior

$ docker-compose ps
…list of running containers from project…

Actual behavior

$ docker-compose ps
Traceback (most recent call last):
File “”, line 3, in
File “compose/cli/”, line 58, in main
File “compose/cli/”, line 109, in perform_command
File “compose/cli/”, line 462, in ps
File “compose/”, line 457, in containers
File “compose/”, line 448, in _labeled_containers
File “site-packages/docker/api/”, line 70, in containers
File “site-packages/docker/utils/”, line 47, in inner
File “site-packages/docker/”, line 120, in _get
File “site-packages/requests/”, line 477, in get
File “site-packages/requests/”, line 465, in request
File “site-packages/requests/”, line 573, in send
File “site-packages/requests/”, line 370, in send
File “site-packages/requests/packages/urllib3/”, line 544, in urlopen
File “site-packages/requests/packages/urllib3/”, line 341, in _make_request
File “site-packages/requests/packages/urllib3/”, line 761, in _validate_conn
File “site-packages/requests/packages/urllib3/”, line 253, in connect
File “site-packages/backports/ssl_match_hostname/”, line 147, in match_hostname
backports.ssl_match_hostname.CertificateError: hostname ‘sandbox’ doesn’t match either of ‘’, '’
docker-compose returned -1

$ docker-compose --version
docker-compose version 1.7.1, build 0a9ab35

When I set links from /usr/local/bin to backup-version of docker-compose, error is gone. with new version only clear the DOCKER_TLS_VERIFY environment is work, but with warnings of course.

$ docker-compose --version
docker-compose version 1.6.2, build 4d72027


$ pinata diagnose -u
OS X: version 10.11.4 (build: 15E65) version v1.11.1-beta12
Running diagnostic tests:
[ERROR] docker-cli wrong Docker version: 1.10.3 (expected 1.11.1)
[OK] Moby booted
[OK] driver.amd64-linux
[OK] vmnetd
[OK] osxfs
[OK] db
[OK] slirp
[OK] menubar
[ERROR] environment the variables DOCKER_CERT_PATH DOCKER_TLS_VERIFY DOCKER_HOST should not be set
[OK] Docker
[OK] VT-x
Docker logs are being collected into /tmp/20160518-152308.tar.gz
Most specific failure is: the variables DOCKER_CERT_PATH DOCKER_TLS_VERIFY DOCKER_HOST should not be set
Your unique id is: 0B0E3854-5019-42FC-864A-FE80E6F902A9
Please quote this in all correspondence.

Steps to reproduce the behavior

  1. Install Docker for Mac beta
  2. Profit :slight_smile:

(Dave Tucker) #2

You might want to check out the docs, specifically

(Otetz) #3

Hm, but my case is not listed yet.
I have linux-box with docker near my mac and try to connect from local Docker for Mac.