Back to godoc.org

Package xen

v0.0.0-...-7ee4457
Latest Go to latest

The latest major version is .

Published: Jul 8, 2016 | License: BSD-2-Clause | Module: github.com/unigornel/unigornel

Index

Constants

const (
	OnCrashPreserve = "preserve"
)

func Console

func Console(id int) *exec.Cmd

func Create

func Create(paused bool, config string) *exec.Cmd

func Destroy

func Destroy(id int) *exec.Cmd

func List

func List() *exec.Cmd

func Unpause

func Unpause(id int) *exec.Cmd

func Xl

func Xl(args ...string) *exec.Cmd

type Domain

type Domain struct {
	ID     int
	Name   string
	Memory int
	VCPUs  int
	State  DomainState
	Time   float64
}

func DomainWith

func DomainWith(f func(Domain) bool) (*Domain, error)

func DomainWithID

func DomainWithID(id int) (*Domain, error)

func DomainWithName

func DomainWithName(name string) (*Domain, error)

func ListDomains

func ListDomains() ([]Domain, error)

func (Domain) Console

func (domain Domain) Console() *exec.Cmd

func (Domain) Destroy

func (domain Domain) Destroy() *exec.Cmd

func (Domain) Unpause

func (domain Domain) Unpause() *exec.Cmd

func (Domain) Update

func (domain Domain) Update() (*Domain, error)

type DomainState

type DomainState int
const (
	DomainStateUnknown  DomainState = 0x00
	DomainStateRunning  DomainState = 0x01
	DomainStateBlocked  DomainState = 0x02
	DomainStatePaused   DomainState = 0x04
	DomainStateShutdown DomainState = 0x08
	DomainStateCrashed  DomainState = 0x10
	DomainStateDying    DomainState = 0x20
)

func (DomainState) Check

func (state DomainState) Check(mask DomainState) bool

type Kernel

type Kernel struct {
	Binary  string
	Memory  int
	Name    string
	OnCrash string
	VIF     string
}

func (*Kernel) CreatePausedUniqueName

func (kernel *Kernel) CreatePausedUniqueName(f func(cmd *exec.Cmd)) (*Domain, error)

func (Kernel) WriteConfiguration

func (k Kernel) WriteConfiguration(w io.Writer)

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier