I try to dockerize my Java app. Whenever I build a new image, Docker adds the new image into the list without removing the old images. I don't run the images, I just build again and again. I think it should remove the old ones. Am I wrong?
Docker file
FROM frolvlad/alpine-oraclejdk8:slim
VOLUME /tmp
ADD ./build/libs/admin-app-0.1.jar app.jar
CMD ["java","-jar","app.jar"]
Commands
sudo gradle build
sudo docker build . -t admin-app:latest
The result