genuinetools / img

Standalone, daemon-less, unprivileged Dockerfile and OCI compatible container image builder.
https://blog.jessfraz.com/post/building-container-images-securely-on-kubernetes/
MIT License
3.88k stars 230 forks source link

Wrong `CREATED` date of pulled image? #316

Open PeterDaveHello opened 3 years ago

PeterDaveHello commented 3 years ago

I pulled the same image from Docker Hub, but the one img pulled will always be created at the moment the pulling finished, which looks a little bit strange, not sure if it's by design?

$ img ls; img pull peterdavehello/tor-socks-proxy; img ls
NAME    SIZE    CREATED AT      UPDATED AT      DIGEST
Pulling peterdavehello/tor-socks-proxy...
Pulled: sha256:5d190656ec0e187476edaf2cbbdcc4ac27878d75161d31c143936e8aaebb3dfb
Size: 7.559MiB
NAME                                            SIZE            CREATED AT              UPDATED AT              DIGEST
docker.io/peterdavehello/tor-socks-proxy:latest 7.559MiB        Less than a second ago  Less than a second ago  sha256:5d190656ec0e187476edaf2cbbdcc4ac27878d75161d31c143936e8aaebb3dfb
$ docker images; docker pull peterdavehello/tor-socks-proxy; docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
Using default tag: latest
latest: Pulling from peterdavehello/tor-socks-proxy
df20fa9351a1: Pull complete 
3d52f3ffd565: Pull complete 
9ed2538c994c: Pull complete 
Digest: sha256:4d20ab14a705e45b802a842f812f198b20256fffdc343c209031c5f0f8ace216
Status: Downloaded newer image for peterdavehello/tor-socks-proxy:latest
docker.io/peterdavehello/tor-socks-proxy:latest
REPOSITORY                       TAG                 IMAGE ID            CREATED             SIZE
peterdavehello/tor-socks-proxy   latest              20724e4d3939        6 months ago        20.6MB
PeterDaveHello commented 3 years ago

Not sure if it's the same problem as here, the digest above is also different with the one the docker-cli pulled: https://github.com/genuinetools/img/issues/234#issuecomment-568398839