Quickly learn How to remove all exited Docker containers at once with WhaleDeck Shorts. Clear, step-by-step guides for Docker.
The answer is quite simple. The following command shows how to remove all containers with state exited.
docker rm $(docker ps -a -q -f status=exited)