Reputation: 1338
I would like to know how a Docker engine communicate with Docker containers.
For example, when we issue a command docker stop <container-id>
, the docker engine will stop the container with the <container-id>
.
How does these two processes communicate to each other? Is it through signal or some other mechanism?
I understand that Docker CLI talks to Docker Engine via Unix socket (also TCP binding is also possible). What I am looking for is how the Docker engine communicate with Docker containers.
Upvotes: 0
Views: 143
Reputation: 141085
From https://docs.docker.com/engine/reference/commandline/stop/ :
The main process inside the container will receive SIGTERM, and after a grace period, SIGKILL.
Upvotes: 1