Why is the docker image creation date date creation date out of date

I am trying to understand the management of docker / container files. I run the following commands after the build to help save free disk space:

 docker rm $(docker ps -a -q)
 docker images | awk '/^<none>/ {print $3}' | xargs docker rmi

It works well. I sometimes manually delete images using the image id. What eludes me when I delete an image, especially when it is recreated, the created time is reported from the original time frame. I expect this to be the date of its creation. For instance:

 REPOSITORY               TAG                 IMAGE ID            CREATED                  VIRTUAL SIZE
 <none>                   <none>              4eb6a3fb4a76        5 days ago          1.587 GB
 user1/image1             latest              cc710febe57e        5 days ago          1.597 GB

Why? Is the image with saved items from the deleted image saved? I originally created the image 5 days ago. I expect that after creating the image, a new created value will be created today.

Also, a hint in case you don't know ... using --rm with start clears containers after stopping.

+4
source share

All Articles