Usefull commands
Remove
The most elegant way to remove all exitednon-running containersscontainers
seems to be:
docker rm $(docker ps -q -f status=exited)
docker rm $(docker ps -q -f status=exited)
-qprints just the container ids (without column headers)-fallows you to filter your list of printed containers (in this case we are filtering to only show exited containers)