Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to remove <none> images after building successfull

After I build my image, there are a bunch of images. When I try to delete them I get “image has dependent child images” errors. Is there anyway to clean this up?

These do NOT work:

docker rmi $(docker images -q)
docker rmi $(docker images | grep “^” | awk “{print $3}”)
docker rmi $(docker images -f “dangling=true” -q)
like image 318
mahmoodi Avatar asked Jan 25 '23 18:01

mahmoodi


1 Answers

docker rmi `docker images | grep "<none>" | awk {'print $3'}`
like image 62
Vishnu Nair Avatar answered Jan 31 '23 08:01

Vishnu Nair