image

package
v0.0.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Image

type Image struct {
	// ID is a unique identifier for the image. With this identifier the vm.Manager has to be able to identify the image.
	ID   string
	Name string
}

func AddFromURL

func AddFromURL(mgr Manager, pool, name, src string, progress io.Writer) (*Image, error)

type Manager

type Manager interface {
	Create(pool, name string, image io.ReadCloser) (*Image, error)
	Clone(baseImageID, targetPool, targetName string, size uint64) (*Image, error)
	List(pool string) ([]Image, error)
	Get(pool, name string) (*Image, error)
	Remove(ID string) error
}

Manager is the iterface which describes the image management. With create we can create an image in a certain pool (e.g. config isos, base images, images). The pool is to distingush between various image categories. It allows to retrieve only images of a certain type.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL