Skip to content
This repository was archived by the owner on Jan 15, 2026. It is now read-only.
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions image/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,9 @@ func CreateRuntimeBundleLayout(src, dest, ref, root, platform string) error {
return createRuntimeBundle(newPathWalker(src), dest, ref, root, platform)
}

// CreateRuntimeBundleFile opens the file pointed by tarFile and calls
// CreateRuntimeBundle.
// CreateRuntimeBundleFile walks through the tar file given by tarFile
// and creates an OCI runtime bundle in the given destination dest
// or returns an error if the unpacking failed.
func CreateRuntimeBundleFile(tarFile, dest, ref, root, platform string) error {
f, err := os.Open(tarFile)
if err != nil {
Expand All @@ -233,13 +234,6 @@ func CreateRuntimeBundleFile(tarFile, dest, ref, root, platform string) error {
return createRuntimeBundle(newTarWalker(f), dest, ref, root, platform)
}

// CreateRuntimeBundle walks through the given tar stream and
// creates an OCI runtime bundle in the given destination dest
// or returns an error if the unpacking failed.
func CreateRuntimeBundle(r io.ReadSeeker, dest, ref, root, platform string) error {
return createRuntimeBundle(newTarWalker(r), dest, ref, root, platform)
}

func createRuntimeBundle(w walker, dest, refName, rootfs, platform string) error {
if err := layoutValidate(w); err != nil {
return err
Expand Down