Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

docker container don't stop

I am trying to launch a network of containers using docker-compose, when I want to stop this network I executed

  docker-compose down

some containers didn't stop, I tried

  docker rm $(docker ps -a -q)

but it didn't execute, I receive no response after running this command! I have tried this command also :

docker rm id_container

Does anyone have an idea on how to force this container to stop?

like image 262
MS B Avatar asked Jun 08 '26 05:06

MS B


1 Answers

Sometimes docker hangs and compose services become ghost services with status pending removal or something like that. Try to restart your host and see if that helps solving the problem.

like image 150
tkyass Avatar answered Jun 10 '26 02:06

tkyass



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!