MCPcopy Create free account
hub / github.com/containers/image / GetBlob

Method GetBlob

docker/docker_image_src.go:456–458  ·  view source on GitHub ↗

GetBlob returns a stream for the specified blob, and the blob’s size (or -1 if unknown). The Digest field in BlobInfo is guaranteed to be provided, Size may be -1 and MediaType may be optionally provided. May update BlobInfoCache, preferably after it knows for certain that a blob truly exists at a s

(ctx context.Context, info types.BlobInfo, cache types.BlobInfoCache)

Source from the content-addressed store, hash-verified

454// The Digest field in BlobInfo is guaranteed to be provided, Size may be -1 and MediaType may be optionally provided.
455// May update BlobInfoCache, preferably after it knows for certain that a blob truly exists at a specific location.
456func (s *dockerImageSource) GetBlob(ctx context.Context, info types.BlobInfo, cache types.BlobInfoCache) (io.ReadCloser, int64, error) {
457 return s.c.getBlob(ctx, s.physicalRef, info, cache)
458}
459
460// GetSignaturesWithFormat returns the image's signatures. It may use a remote (= slow) service.
461// If instanceDigest is not nil, it contains a digest of the specific manifest instance to retrieve signatures for

Callers

nothing calls this directly

Calls 1

getBlobMethod · 0.80

Tested by

no test coverage detected