Interview Prep/Docker/Containers, VMs & Isolation Internals

Explain `docker stop` vs `docker kill`.

BeginnerConceptContainers, VMs & Isolation Internals
Answer

docker stop sends SIGTERM (or the image's STOPSIGNAL), waits 10 seconds by default (-t to change), then sends SIGKILL. docker kill sends SIGKILL immediately (or any signal via -s). Graceful shutdown depends on your app handling SIGTERM as PID 1.

All Docker questions Roadmap: Docker & containers

More on Containers, VMs & Isolation Internals