// ImageStatus returns the status of a given image
ImageStatus returns the status of a given image
// ImageStatus returns the status of a given image
func (s *ImageService) ImageStatus(ctx context.Context, req *runtimeapi.ImageStatusRequest) (*runtimeapi.ImageStatusResponse, error) {
	image, _, err := s.client.ImageInspectWithRaw(ctx, req.GetImage().GetImage())
	resp := &runtimeapi.ImageStatusResponse{}
	if err != nil {
		return resp, nil
	}
	resp.Image = &runtimeapi.Image{
		Id:          image.ID,
		RepoTags:    image.RepoTags,
		RepoDigests: image.RepoDigests,
		Size_:       uint64(image.Size),
	}
	return resp, nil
}
func ( s * ImageService ) ImageStatus ( ctx context . Context , req * runtimeapi . ImageStatusRequest ) ( * runtimeapi . ImageStatusResponse , error ) { image , _ , err := s . client . ImageInspectWithRaw ( ctx , req . GetImage ( ) . GetImage ( ) ) resp := & runtimeapi . ImageStatusResponse { } if err != nil { return resp , nil } resp . Image = & runtimeapi . Image { Id : image . ID , RepoTags : image . RepoTags , RepoDigests : image . RepoDigests , Size_ : uint64 ( image . Size ) , } return resp , nil }
ImageStatus returns the status of a given image
ImageStatus returns the status of a given image