Docker Socket Without TLS
I have a TLS secured docker demon running. I use TLS for remote accessing the docker demon and access docker locally without any TLS. Normally…
Recently, I have updated Docker. Apparently I cannot connect to the local socket anymore. I suppose Docker is using now TLS for remote and local connections.
Is there a way to disable TLS for the local Docker socket?
ps auxw | grep dockerd:
/usr/bin/dockerd -H 0.0.0.0:2376 –tlsverify –tlscacert /home/dockermanager/.docker/ca.pem –tlscert /home/dockermanager/.docker/server-cert.pem –tlskey /home/dockermanager/.docker/server-key.pem
One Solution collect form web for “Docker Socket Without TLS”
Had been able to fix this myself.
I needed to migrate to these two systemd files provided by Docker:
One service file is for the docker demon and there is one for the docker socket separately. The docker socket is a required dependency by docker.service and will be loaded, restartet and stopped accordingly.
Then i needed to add the docker demon parameter
-H unix:// in order to activate the docker demon listening to the docker socket.
Afterwards everything worked as always and I assume local docker.socket communication does not need tls verification at all.
Start command now:
/usr/bin/dockerd -H unix:// -H tcp://0.0.0.0:2376 --tlsverify --tlscacert /home/dockeruser/.docker/ca.pem --tlscert /home/dockeruser/.docker/server-cert.pem --tlskey /home/dockeruser/.docker/server-key.pem