Documentation ¶
Index ¶
- Variables
- func ParseLabelTime(s string) (time.Time, error)
- func SplitVariants(s string) (prefix string, variants []string)
- func SystemLabel(system *System, note string) string
- type Backend
- type Client
- func (c *Client) Close() error
- func (c *Client) CombinedOutput(script string, dir string, env *Environment) (output []byte, err error)
- func (c *Client) MissingOrEmpty(dir string) (bool, error)
- func (c *Client) Output(script string, dir string, env *Environment) (output []byte, err error)
- func (c *Client) ReadFile(path string) ([]byte, error)
- func (c *Client) RecvTar(packDir string, include []string, tar io.Writer) error
- func (c *Client) RemoveAll(path string) error
- func (c *Client) ResetJob()
- func (c *Client) Run(script string, dir string, env *Environment) error
- func (c *Client) Send(from, to string, include, exclude []string) error
- func (c *Client) SendTar(tar io.Reader, unpackDir string) error
- func (c *Client) Server() Server
- func (c *Client) SetJob(job string)
- func (c *Client) SetKillTimeout(timeout time.Duration)
- func (c *Client) SetWarnTimeout(timeout time.Duration)
- func (c *Client) SetupRootAccess(password string) error
- func (c *Client) Shell(script string, dir string, env *Environment) error
- func (c *Client) Trace(script string, dir string, env *Environment) (output []byte, err error)
- func (c *Client) WriteFile(path string, data []byte) error
- type Distro
- type Environment
- func (e *Environment) Copy() *Environment
- func (e *Environment) Get(key string) string
- func (e *Environment) Keys() []string
- func (e *Environment) MarshalYAML() (interface{}, error)
- func (e *Environment) Replace(oldkey, newkey, value string)
- func (e *Environment) Set(key, value string)
- func (e *Environment) UnmarshalYAML(u func(interface{}) error) error
- func (e *Environment) Unset(key string)
- func (e *Environment) Variant(variant string) *Environment
- type FatalError
- type Filter
- type Job
- func (job *Job) Debug() string
- func (job *Job) KillTimeoutFor(context interface{}) time.Duration
- func (job *Job) Prepare() string
- func (job *Job) Restore() string
- func (job *Job) String() string
- func (job *Job) StringFor(context interface{}) string
- func (job *Job) WarnTimeoutFor(context interface{}) time.Duration
- type OptionalInt
- type Options
- type Project
- type Provider
- func AdHoc(p *Project, b *Backend, o *Options) Provider
- func Google(p *Project, b *Backend, o *Options) Provider
- func Humbox(p *Project, b *Backend, o *Options) Provider
- func LXD(p *Project, b *Backend, o *Options) Provider
- func Linode(p *Project, b *Backend, o *Options) Provider
- func QEMU(p *Project, b *Backend, o *Options) Provider
- type Reuse
- type ReuseBackend
- type ReuseSystem
- type Runner
- type Server
- type Size
- type Suite
- type System
- type SystemsMap
- type Task
- type Timeout
- type UnknownServer
Constants ¶
This section is empty.
Variables ¶
View Source
var Debug bool
Debug defines whether to also deliver debug messages to the log. Implies Verbose if set.
View Source
var Logger *stdlog.Logger
Logger defines the logger where messages should be sent to.
View Source
var Verbose bool
Verbose defines whether to also deliver verbose messages to the log.
Functions ¶
func SplitVariants ¶
func SystemLabel ¶
Types ¶
type Backend ¶
type Backend struct { Name string `yaml:"-"` Type string Key string // Only for adhoc. Allocate string Discard string // Only for qemu so far. Memory Size // Only for Linode and Google so far. Plan string Location string Storage Size Systems SystemsMap Prepare string Restore string Debug string PrepareEach string `yaml:"prepare-each"` RestoreEach string `yaml:"restore-each"` DebugEach string `yaml:"debug-each"` Environment *Environment Variants []string WarnTimeout Timeout `yaml:"warn-timeout"` KillTimeout Timeout `yaml:"kill-timeout"` HaltTimeout Timeout `yaml:"halt-timeout"` Priority OptionalInt Manual bool }
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) CombinedOutput ¶
func (*Client) SetKillTimeout ¶
func (*Client) SetWarnTimeout ¶
func (*Client) SetupRootAccess ¶
type Environment ¶
type Environment struct {
// contains filtered or unexported fields
}
func NewEnvironment ¶
func NewEnvironment(pairs ...string) *Environment
func (*Environment) Copy ¶
func (e *Environment) Copy() *Environment
func (*Environment) Get ¶
func (e *Environment) Get(key string) string
func (*Environment) Keys ¶
func (e *Environment) Keys() []string
func (*Environment) MarshalYAML ¶
func (e *Environment) MarshalYAML() (interface{}, error)
func (*Environment) Replace ¶
func (e *Environment) Replace(oldkey, newkey, value string)
func (*Environment) Set ¶
func (e *Environment) Set(key, value string)
func (*Environment) UnmarshalYAML ¶
func (e *Environment) UnmarshalYAML(u func(interface{}) error) error
func (*Environment) Unset ¶
func (e *Environment) Unset(key string)
func (*Environment) Variant ¶
func (e *Environment) Variant(variant string) *Environment
type FatalError ¶
type FatalError struct {
// contains filtered or unexported fields
}
FatalError represents an error that cannot be fixed by just retrying.
type Job ¶
type Job struct { Name string Project *Project Backend *Backend System *System Suite *Suite Task *Task Variant string Environment *Environment Sample int Priority int64 }
func (*Job) KillTimeoutFor ¶
func (*Job) WarnTimeoutFor ¶
type OptionalInt ¶
func (OptionalInt) String ¶
func (s OptionalInt) String() string
func (*OptionalInt) UnmarshalYAML ¶
func (s *OptionalInt) UnmarshalYAML(u func(interface{}) error) error
type Project ¶
type Project struct { Name string `yaml:"project"` Backends map[string]*Backend Environment *Environment Repack string Prepare string Restore string Debug string PrepareEach string `yaml:"prepare-each"` RestoreEach string `yaml:"restore-each"` DebugEach string `yaml:"debug-each"` Suites map[string]*Suite RemotePath string `yaml:"path"` Include []string Exclude []string Rename []string Path string `yaml:"-"` WarnTimeout Timeout `yaml:"warn-timeout"` KillTimeout Timeout `yaml:"kill-timeout"` }
type Provider ¶
type Reuse ¶
type Reuse struct {
// contains filtered or unexported fields
}
func (*Reuse) ReuseSystems ¶
func (r *Reuse) ReuseSystems(system *System) []*ReuseSystem
type ReuseBackend ¶
type ReuseBackend struct {
Systems []*ReuseSystem `yaml:",omitempty"`
}
type ReuseSystem ¶
type ReuseSystem struct { Name string `yaml:"-"` Username string `yaml:",omitempty"` Password string Address string Data interface{} `yaml:",omitempty"` }
func (ReuseSystem) MarshalYAML ¶
func (rsys ReuseSystem) MarshalYAML() (interface{}, error)
func (*ReuseSystem) UnmarshalData ¶
func (rsys *ReuseSystem) UnmarshalData(v interface{}) error
func (*ReuseSystem) UnmarshalYAML ¶
func (rsys *ReuseSystem) UnmarshalYAML(u func(interface{}) error) error
type Suite ¶
type Suite struct { Summary string Systems []string Backends []string Variants []string Environment *Environment Prepare string Restore string Debug string PrepareEach string `yaml:"prepare-each"` RestoreEach string `yaml:"restore-each"` DebugEach string `yaml:"debug-each"` Name string `yaml:"-"` Path string `yaml:"-"` Tasks map[string]*Task `yaml:"-"` WarnTimeout Timeout `yaml:"warn-timeout"` KillTimeout Timeout `yaml:"kill-timeout"` Priority OptionalInt Manual bool }
type System ¶
type System struct { Backend string `json:"-"` Name string Image string Kernel string Username string Password string Workers int // Only for Linode and Google so far. Storage Size // Only for Google so far. SecureBoot bool `yaml:"secure-boot"` // Specify a backend specific plan, e.g. `e2-standard-2` Plan string Environment *Environment Variants []string Priority OptionalInt Manual bool }
func (*System) UnmarshalYAML ¶
type SystemsMap ¶
func (*SystemsMap) UnmarshalYAML ¶
func (sysmap *SystemsMap) UnmarshalYAML(u func(interface{}) error) error
type Task ¶
type Task struct { Suite string `yaml:"-"` Summary string Details string Systems []string Backends []string Variants []string Environment *Environment Samples int Prepare string Restore string Execute string Debug string Artifacts []string Name string `yaml:"-"` Path string `yaml:"-"` WarnTimeout Timeout `yaml:"warn-timeout"` KillTimeout Timeout `yaml:"kill-timeout"` Priority OptionalInt Manual bool }
type Timeout ¶
func (*Timeout) UnmarshalYAML ¶
type UnknownServer ¶
type UnknownServer struct {
Addr string
}
Click to show internal directories.
Click to hide internal directories.