Documentation
¶
Index ¶
Constants ¶
const RootfsName = "rootfs"
RootfsName is the name of the rootfs directory inside the bundle path when generated.
Variables ¶
This section is empty.
Functions ¶
func GenerateLayer ¶
func GenerateLayer(path string, deltas []mtree.InodeDelta) (io.ReadCloser, error)
GenerateLayer creates a new OCI diff layer based on the mtree diff provided. All of the mtree.Modified and mtree.Extra blobs are read relative to the provided path (which should be the rootfs of the layer that was diffed). The returned reader is for the *raw* tar data, it is the caller's responsibility to gzip it.
func UnpackLayer ¶
UnpackLayer unpacks the tar stream representing an OCI layer at the given root. It ensures that the state of the root is as close as possible to the state used to create the layer. If an error is returned, the state of root is undefined (unpacking is not guaranteed to be atomic).
func UnpackManifest ¶
func UnpackManifest(ctx context.Context, engine cas.Engine, bundle string, manifest v1.Manifest) error
UnpackManifest extracts all of the layers in the given manifest, as well as generating a runtime bundle and configuration. The rootfs is extracted to <bundle>/<layer.RootfsName>. Some verification is done during image extraction.
FIXME: This interface is ugly.
Types ¶
This section is empty.