Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Docker TLS error on Mac

Tags:

docker

I ran docker images and got the following error:

FATA[0000] Get http:///var/run/docker.sock/v1.17/images/json:
dial unix /var/run/docker.sock: no such file or directory.
Are you trying to connect to a TLS-enabled daemon without TLS?

There seems to be no useful message on how to fix the error. What could be wrong?

like image 837
Pranjal Mittal Avatar asked Apr 12 '15 21:04

Pranjal Mittal


People also ask

What is TLS Docker?

Use TLS (HTTPS) to protect the Docker daemon socket. If you need Docker to be reachable through HTTP rather than SSH in a safe manner, you can enable TLS (HTTPS) by specifying the tlsverify flag and pointing Docker's tlscacert flag to a trusted CA certificate.

How do you expose Docker daemon without TLS?

on the Notification bar, select Settings from the context menu, and then select the Expose daemon on tcp://localhost:2375 without TLS checkbox in the General section of your system Docker settings.

What hypervisor does Docker use on Mac?

app is Docker Desktop on Mac. It bundles the Docker client and Docker Engine. Docker. app uses the macOS Hypervisor.


1 Answers

https://docs.docker.com/installation/mac/

you need to do this once:

boot2docker init

then, everytime you reboot your mac you will need to run :

boot2docker start

That is the command that starts the docker daemon. But, on each shell you want to access it from you will need to run:

$(boot2docker shellinit)

Now you can use the docker client, like:

docker run hello-world
like image 199
Greg Avatar answered Oct 07 '22 07:10

Greg