Documentation ¶
Overview ¶
Package store implements OCI container storage.
Index ¶
Constants ¶
const ( DirDigests = "d" DirImages = "i" DirOverlays = "o" DirContainers = "c" )
Store directories. Shorter is better, to avoid passing too much data to the mount syscall when creating an overlay mount with many layers as lower directories.
const ( DirRootFS = "rootfs" FileConfig = "config.json" FileSpec = "config.json" )
Bundle paths.
Variables ¶
var (
// MaxLayers is the maximum number of layers an image can have.
MaxLayers = 256
)
Functions ¶
Types ¶
type Bundle ¶
type Bundle interface { // Path of the OCI bundle. Path() string // Cleanup the OCI bundle after the container has finished running. Cleanup() error }
A Bundle for use by an OCI runtime.
type Bundler ¶
type Bundler interface { // Bundle returns an OCI bundle ready for use by an OCI runtime. Bundle(ctx context.Context, i ociv1.Image, id string, o ...spec.Option) (Bundle, error) }
A Bundler prepares OCI runtime bundles for use by an OCI runtime.
type Digest ¶
type Digest struct {
// contains filtered or unexported fields
}
A Digest store is used to map OCI references to digests. Each mapping is a file. The filename is the SHA256 hash of the reference, and the content is the digest in algo:hex format.
type Image ¶
type Image struct {
// contains filtered or unexported fields
}
An Image store is used to store OCI images and their layers. It uses a similar disk layout to the blobs directory of an OCI image layout, but may contain blobs for more than one image. Layers are stored as uncompressed tarballs in order to speed up extraction by the uncompressed Bundler, which extracts a fresh root filesystem each time a container is run. https://github.com/opencontainers/image-spec/blob/v1.0/image-layout.md
func (*Image) WriteImage ¶
WriteImage writes the supplied image to the store.
Directories ¶
Path | Synopsis |
---|---|
Package overlay implements an overlay based container store.
|
Package overlay implements an overlay based container store. |
Package uncompressed implemented an uncompressed layer based container store.
|
Package uncompressed implemented an uncompressed layer based container store. |