Jib: Jib Image Built 48 Years Ago? (49 years ago / 50 years ago / 51 years ago / 52 years ago / 53 years ago / 54 years ago / 55 years ago / ...)

Created on 13 Jul 2018  路  3Comments  路  Source: GoogleContainerTools/jib

Description of the issue:

I built an image with Jib, tried it on ECS -- didn't work. So I wanted to try it locally to diagnose what might be going wrong, so I did a mvn jib:dockerBuild. I then listed my images with docker images and the jib image wasn't at the top of the list. I looked around and found it, all the way at the bottom. Under the CREATED column, the jib-built image says, "48 years ago".

The date looks ok on ECR, but that's the pushed at date. I tried pulling from ECR to my local docker and the image I got that way was also created 48 years ago.

So either I built this docker image back in 1970 before I was born, or, possibly, there's some kind of issue here, likely an epoch milliseconds of 0 somewhere.

I'm not sure where this date comes, so I don't really know that it's a jib issue per se, but none of my other images have had this problem, so ... my first guess is that somehow it has something to do with jib? Feel free to tell me that I'm wrong. ;)

Expected behavior:

Kinda expected the image to appear at the top of the list, created N minutes ago.

Steps to reproduce:

mvn jib:dockerBuild

or
mvn jib:build
followed by
docker pull <ECR_IMAGE>

Environment:
macOS 10.13.5
Maven 3.5.4
Java 1.8.0_172
Docker v18.03.1-ce

Most helpful comment

The timestamp is removed to maintain image reproducibility, so this is working as intended for now. However, we are discussing alternative ways of setting the timestamp since this issue seems to be coming up a lot.

We have #413 open to track this, so I'll close this one. Feel free to comment on that one.

All 3 comments

The timestamp is removed to maintain image reproducibility, so this is working as intended for now. However, we are discussing alternative ways of setting the timestamp since this issue seems to be coming up a lot.

We have #413 open to track this, so I'll close this one. Feel free to comment on that one.

I have the same problem, after the build there is an image built 50 years ago

@freedev this is working as intended. If you want, you can control the image creation time with <creationTime>. Also see this FAQ.

Was this page helpful?
0 / 5 - 0 ratings