I’m using Docker Desktop for Mac and utilizing
docker context to connect to remote servers via SSH. I then build and deploy services using Docker Compose. Everything seems to work normally, however, recently when I checked the server logs, I noticed that my machine was persistently making SSH connections to the remote server, connecting every few seconds.
root@aaaaaaaaa:~# tail -f /var/log/auth.log | grep Accepted May 21 06:56:09 aaaaaaaa sshd: Accepted publickey for root from 188.8.131.52 port 57088 ssh2: ED25519 SHA256:xxxxxxxxxxxxxxxx
When I checked my local machine with
pstree, I found that com.docker.build was constantly making SSH connections to the remote servers and executing the
docker system dial-stdio command.
pstree -u $USER 06567 -+- 06567 tao com.docker.build |--= 06609 tao ssh -- law-us docker system dial-stdio |--= 06632 tao ssh -- shui-us docker system dial-stdio |--= 06633 tao ssh -- law-us docker system dial-stdio |--= 07561 tao ssh -- shui-us docker system dial-stdio ...
Interestingly, at this time, I am not even using the context of these servers. My current context is the local system. I’m wondering what could be causing this? How can I prevent these seemingly meaningless connection attempts?
The version of my current setup is:
- Docker Desktop: 4.19.0 (106363)
- Docker version:
Client: Docker Engine - Community Version: 23.0.2 API version: 1.42 Go version: go1.20.2 Git commit: 569dd73db1 Built: Mon Mar 27 15:44:26 2023 OS/Arch: darwin/arm64 Context: desktop-linux Server: Docker Desktop 4.19.0 (106363) Engine: Version: 23.0.5 API version: 1.42 (minimum version 1.12) Go version: go1.19.8 Git commit: 94d3ad6 Built: Wed Apr 26 16:17:14 2023 OS/Arch: linux/arm64 Experimental: false containerd: Version: 1.6.20 GitCommit: 2806fc1057397dbaeefbea0e4e17bddfbd388f38 runc: Version: 1.1.5 GitCommit: v1.1.5-0-gf19387a docker-init: Version: 0.19.0 GitCommit: de40ad0
- Docker Compose version: v2.17.3
- Docker Buildx version: GitHub - docker/buildx: Docker CLI plugin for extended build capabilities with BuildKit v0.10.4 c513d34049e499c53468deac6c4267ee72948f02