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
check this:
ps | grep -i a66 | tr -s ' '|cut -f2 -d' '| { while read line; do kill -9 $line; done }
to understand this start from executing commands from left till end of each pipe (|)
Simpler option:
kill $(pidof a66)