Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dockerhub 1.14.2-alpine image hash mysteriously changed #307

Closed
dan-frohlich opened this issue Jan 31, 2019 · 2 comments
Closed

Dockerhub 1.14.2-alpine image hash mysteriously changed #307

dan-frohlich opened this issue Jan 31, 2019 · 2 comments

Comments

@dan-frohlich
Copy link

on Thu Jan 31 13:11:42 EST 2019 I observed
$ docker images | grep -i "nginx.*alpine|CREATED"
REPOSITORY TAG IMAGE ID CREATED SIZE
nginx 1.14.2-alpine 3058c2eef045 17 hours ago 17.7MB

yesterday it was
nginx 1.14.2-alpine c5b6f731fbc0 5 weeks ago 17.7MB

What happened to the IMAGE ?!?!

@tianon
Copy link
Contributor

tianon commented Jan 31, 2019

So, a couple things (and hopefully some resources to help you answer this for yourself in the future).

To start with, from https://github.com/docker-library/official-images#library-definition-files:

Tags in the library file are only built through an update to that library file or as a result of its base image being updated (ie, an image FROM debian:jessie would be rebuilt when debian:jessie is built). Only what is in the library file will be rebuilt when a base has updates.

Additionally the https://github.com/docker-library/repo-info repository (linked from https://hub.docker.com/_/nginx under "Published image artifact details:" in the "Quick Reference") has a wealth of detailed information about published artifacts.

If you look at https://github.com/docker-library/repo-info/blob/dd7dbb144629c7033e0caebb96f35de5b7664296/repos/nginx/remote/1.14.2-alpine.md, you can see information about the current artifact (under https://github.com/docker-library/repo-info/blob/dd7dbb144629c7033e0caebb96f35de5b7664296/repos/nginx/remote/1.14.2-alpine.md#nginx1142-alpine---linux-amd64, you can see the image ID you've referenced, sha256:3058c2eef0451e0bb492bebc21183cbe499bd96c7d92f6bf122521fa1efda5b5 / 3058c2eef045).

If you check the history on that file, you can trace back to docker-library/repo-info@9492ce8#diff-28a2ee9214b63bac88fbecd0ade8c536, which shows the exact changes between c5b6f731fbc0 and 3058c2eef045, including the full digest you can use to pull that exact older image if you just need the older bits.

In this case, I can give you a little hint and point out docker-library/official-images#5367, which updated the alpine:3.8 base this image is built upon, so that's likely the source of this particular rebuild (and docker-library/official-images#5377 is going to do so again, updating the base to Alpine 3.9).

@dan-frohlich
Copy link
Author

Thanks so much for the detailed answer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants