MCPcopy Index your code
hub / github.com/linuxkit/linuxkit / ImageSource

Interface ImageSource

src/cmd/linuxkit/spec/image.go:12–25  ·  view source on GitHub ↗

ImageSource interface to an image. It can have its config read, and a its containers can be read via an io.ReadCloser tar stream.

Source from the content-addressed store, hash-verified

10// ImageSource interface to an image. It can have its config read, and a its containers
11// can be read via an io.ReadCloser tar stream.
12type ImageSource interface {
13 // Descriptor get the v1.Descriptor of the image
14 Descriptor() *v1.Descriptor
15 // Config get the config for the image
16 Config() (imagespec.ImageConfig, error)
17 // TarReader get the flattened filesystem of the image as a tar stream
18 TarReader() (io.ReadCloser, error)
19 // V1TarReader get the image as v1 tarball, also compatible with `docker load`. If name arg is not "", override name of image in tarfile from default of image.
20 V1TarReader(overrideName string) (io.ReadCloser, error)
21 // OCITarReader get the image as an OCI tarball, also compatible with `docker load`. If name arg is not "", override name of image in tarfile from default of image.
22 OCITarReader(overrideName string) (io.ReadCloser, error)
23 // SBoM get the sbom for the image, if any is available
24 SBoMs() ([]io.ReadCloser, error)
25}
26
27// IndexSource interface to an image. It can have its config read, and a its containers
28// can be read via an io.ReadCloser tar stream.

Callers 5

ValidateImageMethod · 0.65
cacheExportCmdFunction · 0.65
cacheExportCmdFunction · 0.65
BuildMethod · 0.65
cacheExportCmdFunction · 0.65

Implementers 3

ImageSourcesrc/cmd/linuxkit/cache/imagesource.go
cacheMockerSourcesrc/cmd/linuxkit/pkglib/build_test.go
ImageSourcesrc/cmd/linuxkit/docker/source.go

Calls

no outgoing calls

Tested by

no test coverage detected