It happened to me several times when I made some changes in configuration files and restarted container to apply changes. From time to time happened that configuration had some problem and container was not running properly but kept restarting itself.
Usually happened that I was not able to neither DOCKER STOP nor to DOCKER KILL container. After “stop” attempt container was still present in PS output. When I tried another DOCKER STOP or DOCKER KILL command I got response like this:
“Error response from daemon: Cannot kill container: c5a6aad8a0bc: Container c5a6aad8a0bc7f4469105bf5c34663a7b7c9ec425bccb9cb15b09fa64d6c92fb is not running”
Nothing from STOP, KILL, RM, RMI commands worked. Container was still running according to DOCKER PS output.
I such case the best option working for me was to restart docker service (sudo docker service stop/ start) + use docker rm -f command after it – it works very well