I have simple example from official guide at docker website.
I run the following:
sudo docker run -d ubuntu:latest /bin/sh -c \"while true; do echo hello
Took me a while to find the right answer, but you will have to manage this process from within the container. When you run docker top a66
from the host, the PIDs are from your host, although that's not quite the case if using Cygwin. Regardless, you will need to bash
or what-have-you back into your container and use commands like ps aux
and kill
while in the container to find and manage the different PIDs for the same processes there.