package cim

import "github.com/Microsoft/hcsshim/pkg/ociwclayer/cim"

Index

Functions

func DestroyCimLayer

func DestroyCimLayer(layerPath string) error

func ImportCimLayerFromTar

func ImportCimLayerFromTar(ctx context.Context, r io.Reader, layerPath string, parentLayerPaths []string) (int64, error)

ImportCimLayerFromTar reads a layer from an OCI layer tar stream and extracts it into the CIM format at the specified path. The caller must specify the parent layers, if any, ordered from lowest to highest layer. This function expects that the layer paths (both the layer that is being imported & the parent layers) are formatted like `.../snapshots/<id>` and the corresponding layer CIMs are located/will be created at `.../snapshots/cim-layers/<id>.cim`. Each CIM file also has corresponding region & objectID files and those files will also be stored inside the `cim-layers` directory.

This function returns the total size of the layer's files, in bytes.

Source Files

import.go

Version
v0.12.6
Published
Aug 19, 2024
Platform
windows/amd64
Imports
15 packages
Last checked
3 hours ago

Tools for package owners.