mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-02 11:18:16 +00:00
Add image_id to CRI ContainerStatus message
There is a conversion function `ConvertPodStatusToRunningPod`, which
can override the `Container.ImageID` into a digested reference from the
`ContainerStatus` CRI RPC, which gets mapped from the `image_ref`:
411c29c39f/pkg/kubelet/container/helpers.go (L259-L292)
To avoid that failure case, we now introduce the same `image_id` into
the container status and let runtimes separate the fields.
We also add a note that the mapping from the digested reference of the
CRI to the Kubernetes Pod API `ImageID` field is intentional and should
not change.
Follow-up on: https://github.com/kubernetes/kubernetes/pull/123508
Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
This commit is contained in:
@@ -357,6 +357,8 @@ type Status struct {
|
||||
Image string
|
||||
// ID of the image.
|
||||
ImageID string
|
||||
// The digested reference of the image used by the container.
|
||||
ImageRef string
|
||||
// Runtime handler used to pull the image if any.
|
||||
ImageRuntimeHandler string
|
||||
// Hash of the container, used for comparison.
|
||||
|
||||
Reference in New Issue
Block a user