-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Kubelet: Use RepoDigest for ImageID when available #34473
Kubelet: Use RepoDigest for ImageID when available #34473
Conversation
cc @derekwaynecarr @ncdc @dchen1107 This is the new-and-improved "let's not break kubemark" edition. I added a default "empty" |
Jenkins unit/integration failed for commit 39c97aa127af7429e8ec1e4f86336375031cd146. Full PR test history. The magic incantation to run this job again is |
e061af5
to
135f87d
Compare
whoops, the "run on rebased branch" messed things up. Rebased manually and restored the necessary commit. |
Previously, the `InspectImage` method of the Docker interface expected a "pullable" image ref (name, tag, or manifest digest). If you tried to inspect an image by its ID (config digest), the inspect would fail to validate the image against the input identifier. This commit changes the original method to be named `InspectImageByRef`, and introduces a new method called `InspectImageByID` which validates that the input identifier was an image ID.
Previously, we used the docker config digest (also called "image ID" by Docker) for the value of the `ImageID` field in the container status. This was not particularly useful, since the config manifest is not what's used to identify the image in a registry, which uses the manifest digest instead. Docker 1.12+ always populates the RepoDigests field with the manifest digests, and Docker 1.10 and 1.11 populate it when images are pulled by digest. This commit changes `ImageID` to point to the the manifest digest when available, using the prefix `docker-pullable://` (instead of `docker://`)
@k8s-bot gke e2e test this |
Jenkins GCI GKE smoke e2e failed for commit 135f87d. Full PR test history. The magic incantation to run this job again is |
Jenkins GKE smoke e2e failed for commit 135f87d. Full PR test history. The magic incantation to run this job again is |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue |
Previously, we used the docker config digest (also called "image ID"
by Docker) for the value of the
ImageID
field in the container status.This was not particularly useful, since the config manifest is not
what's used to identify the image in a registry, which uses the manifest
digest instead. Docker 1.12+ always populates the RepoDigests field
with the manifest digests, and Docker 1.10 and 1.11 populate it when
images are pulled by digest.
This commit changes
ImageID
to point to the the manifest digest whenavailable, using the prefix
docker-pullable://
(instead ofdocker://
)Related to #32159
This change is