![]() What is traefik? It’s “The Cloud Native Edge Router” which means it’s a reverse proxy and load balancer for HTTP and TCP-based applications. Side note: In this example I’m using the traefik image. There are no manifests available for those. Issue #2: The script doesn’t work for Windows images. Issue #1: If the image no longer exists on the Docker Registry. ![]() I’m also limiting the search to 10 tags in this example to keep the output small.Īnd the find version tag script found it! The local image ID matches an image ID on the Docker Registry with a tag of 1.7.20! I *think* I’m running something in version 1.7.x. Instead, you can filter the results a bit. The total number of tags for traefik images is 610! You could use this script to check every one, but that will take a minute or two. This example is searching for an image named traefik, with an image ID of 96c63a7d3e50 (which we got from running docker images. Limit reached, consider increasing limit (-l ) or use more specific filter (-f ) If you don’t want to do all of this manually, you can use my script (on GitHub). But let’s focus on Docker Hub, since that’s a huge public image repository. You can get every tag from a Docker Registry (like Docker Hub), then use every tag you found, to get the image ID information from the manifest of every image.ĭocker Hub has some quirks compared to a proper Docker Registry, and the API isn’t well documented. There’s a way to check all version tags on Docker Hub (for example), against the local docker image’s “Image ID”. If your image is from Docker Hub, they have a new experimental tool you can use called “ Docker Hub Tool“.īut what if you are unlucky? What if there’s a way to check all version tags of an image? Find Version Tag for Latest Docker image Pull a bunch of images and hope the Image ID matches. Traefik latest 96c63a7d3e50 2 months ago 85.7MB It’s very helpful, be sure to install it. If you’re lucky, the developer added a label to the image with the version. How do you find what version latest was? I hope you’re Lucky. ![]() All those docker containers you have running are using images with the :latest tag. Now that you will never use latest again, you could still have a problem. So the latest that was version 1, now turned into version 2. But, only if I was actually using a specific image version and not latest would this be okay. This is fine, since they tagged the new releases as version 2. An image I was using introduced breaking changes. ![]() This article describes why latest is bad.įor me, in this theoretical example. This is how you can find the version of that “latest” image you have running.Įvery time you build a new image, use a new version for your image tags.Įvery time you pull an image, use a specific image tag version. Do not do this! You will be in a situation where you need to find what version you were actually using. If you’ve ever used Docker, you’ve probably used the latest Docker image tag. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |