Documentation ¶
Index ¶
- Variables
- func ConsoleApp(username string) *types.App
- func DecompressingReader(rd io.Reader) (io.Reader, error)
- func UnpackImage(uri, path, saveAmiPath string) (hsh *types.Hash, err error)
- type Container
- func (c *Container) Destroy() error
- func (c *Container) GetImage() (*Image, error)
- func (c *Container) GetJailStatus(refresh bool) (JailStatus, error)
- func (c *Container) IsEmpty() bool
- func (c *Container) IsLoaded() bool
- func (c *Container) JailName() string
- func (c *Container) Jid() int
- func (c *Container) Kill() error
- func (c *Container) Load() error
- func (c *Container) Prep() error
- func (c *Container) Run(app *types.App) (err1 error)
- func (c *Container) Save() error
- func (c *Container) Spawn() error
- func (c *Container) Stage2(app *types.App) error
- func (c *Container) Status() ContainerStatus
- type ContainerManager
- type ContainerSlice
- type ContainerStatus
- type Destroyable
- type Host
- type Image
- func (img *Image) Build(buildDir string, addFiles []string, buildExec []string) (*Image, error)
- func (img *Image) Clone(snapshot, dest string) (*zfs.Dataset, error)
- func (img *Image) Containers() (children ContainerSlice, _ error)
- func (img *Image) Destroy() (err error)
- func (img *Image) GetApp() *types.App
- func (img *Image) IsEmpty() bool
- func (img *Image) Load() error
- func (img *Image) LoadManifest() error
- func (img *Image) PrettyLabels() imageLabels
- func (img *Image) Run(app *types.App, keep bool) (err1 error)
- func (img *Image) RuntimeApp() schema.RuntimeApp
- func (img *Image) Seal() error
- type ImageManager
- func (imgr *ImageManager) All() (ImageSlice, error)
- func (imgr *ImageManager) Create() (*Image, error)
- func (imgr *ImageManager) Find(query string) (ImageSlice, error)
- func (imgr *ImageManager) Find1(query string) (*Image, error)
- func (imgr *ImageManager) Get(spec interface{}) (*Image, error)
- func (imgr *ImageManager) Import(imageUri, manifestUri string) (*Image, error)
- type ImageSlice
- type JailStatus
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrContainerIsEmpty = errors.New("Container is empty")
View Source
var ErrManyFound = stderrors.New("Multiple results found")
View Source
var ErrNotFound = stderrors.New("Not found")
View Source
var NoJailStatus = JailStatus{}
Functions ¶
func ConsoleApp ¶
func DecompressingReader ¶
FIXME: mostly copy/paste from github.com/appc/spec/actool/validate.go
Types ¶
type Container ¶
type Container struct { Dataset *zfs.Dataset `json:"-"` Manifest schema.ContainerRuntimeManifest `json:"-"` Manager *ContainerManager `json:"-"` // contains filtered or unexported fields }
func GetContainer ¶
func GetContainer(ds *zfs.Dataset, mgr *ContainerManager) (*Container, error)
func NewContainer ¶
func NewContainer(ds *zfs.Dataset, mgr *ContainerManager) *Container
func (*Container) GetJailStatus ¶
func (c *Container) GetJailStatus(refresh bool) (JailStatus, error)
func (*Container) Status ¶
func (c *Container) Status() ContainerStatus
type ContainerManager ¶
func (*ContainerManager) All ¶
func (cmgr *ContainerManager) All() (ContainerSlice, error)
func (*ContainerManager) Clone ¶
func (cmgr *ContainerManager) Clone(img *Image) (*Container, error)
func (*ContainerManager) Get ¶
func (cmgr *ContainerManager) Get(spec interface{}) (*Container, error)
type ContainerSlice ¶
type ContainerSlice []*Container
func (ContainerSlice) Len ¶
func (cc ContainerSlice) Len() int
func (ContainerSlice) Less ¶
func (cc ContainerSlice) Less(i, j int) bool
func (ContainerSlice) Swap ¶
func (cc ContainerSlice) Swap(i, j int)
func (ContainerSlice) Table ¶
func (cc ContainerSlice) Table() [][]string
type ContainerStatus ¶
type ContainerStatus uint
const ( ContainerStatusInvalid ContainerStatus = iota ContainerStatusRunning ContainerStatusDying ContainerStatusStopped )
func (ContainerStatus) String ¶
func (cs ContainerStatus) String() string
type Destroyable ¶
type Destroyable interface {
Destroy() error
}
type Host ¶
type Host struct { Dataset *zfs.Dataset `json:"-"` Images ImageManager Containers ContainerManager Properties *properties.Properties // contains filtered or unexported fields }
func (*Host) GetJailStatus ¶
func (h *Host) GetJailStatus(name string, refresh bool) (JailStatus, error)
func (*Host) Initialize ¶
type Image ¶
type Image struct { Dataset *zfs.Dataset `json:"-"` Manager *ImageManager `json:"-"` Manifest schema.ImageManifest `json:"-"` UUID uuid.UUID `json:"-"` Hash *types.Hash `json:",omitempty"` Origin string Timestamp time.Time }
func (*Image) Containers ¶
func (img *Image) Containers() (children ContainerSlice, _ error)
func (*Image) LoadManifest ¶
func (*Image) PrettyLabels ¶
func (img *Image) PrettyLabels() imageLabels
func (*Image) RuntimeApp ¶
func (img *Image) RuntimeApp() schema.RuntimeApp
type ImageManager ¶
func (*ImageManager) All ¶
func (imgr *ImageManager) All() (ImageSlice, error)
func (*ImageManager) Create ¶
func (imgr *ImageManager) Create() (*Image, error)
func (*ImageManager) Find ¶
func (imgr *ImageManager) Find(query string) (ImageSlice, error)
func (*ImageManager) Get ¶
func (imgr *ImageManager) Get(spec interface{}) (*Image, error)
type ImageSlice ¶
type ImageSlice []*Image
For sorting
func (ImageSlice) Len ¶
func (ii ImageSlice) Len() int
func (ImageSlice) Less ¶
func (ii ImageSlice) Less(i, j int) bool
func (ImageSlice) Swap ¶
func (ii ImageSlice) Swap(i, j int)
func (ImageSlice) Table ¶
func (ii ImageSlice) Table() [][]string
type JailStatus ¶
Click to show internal directories.
Click to hide internal directories.