Documentation ¶
Index ¶
- Constants
- type Addr
- type AddrMap
- func (r AddrMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Addr, error)
- func (r AddrMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Addr, system.Addr, bool)
- func (r *AddrMap) UnmarshalJSON(data []byte) error
- func (r *AddrMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Command
- type CommandMap
- func (r CommandMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Command, error)
- func (r CommandMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Command, system.Command, bool)
- func (r *CommandMap) UnmarshalJSON(data []byte) error
- func (r *CommandMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type DNS
- type DNSMap
- func (r DNSMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*DNS, error)
- func (r DNSMap) AppendSysResourceIfExists(sr string, sys *system.System) (*DNS, system.DNS, bool)
- func (r *DNSMap) UnmarshalJSON(data []byte) error
- func (r *DNSMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type File
- type FileMap
- func (r FileMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*File, error)
- func (r FileMap) AppendSysResourceIfExists(sr string, sys *system.System) (*File, system.File, bool)
- func (r *FileMap) UnmarshalJSON(data []byte) error
- func (r *FileMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Gossfile
- type GossfileMap
- func (r GossfileMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Gossfile, error)
- func (r GossfileMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Gossfile, system.Gossfile, bool)
- func (r *GossfileMap) UnmarshalJSON(data []byte) error
- func (r *GossfileMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Group
- type GroupMap
- func (r GroupMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Group, error)
- func (r GroupMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Group, system.Group, bool)
- func (r *GroupMap) UnmarshalJSON(data []byte) error
- func (r *GroupMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type HTTP
- type HTTPMap
- func (r HTTPMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*HTTP, error)
- func (r HTTPMap) AppendSysResourceIfExists(sr string, sys *system.System) (*HTTP, system.HTTP, bool)
- func (r *HTTPMap) UnmarshalJSON(data []byte) error
- func (r *HTTPMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Interface
- type InterfaceMap
- func (r InterfaceMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Interface, error)
- func (r InterfaceMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Interface, system.Interface, bool)
- func (r *InterfaceMap) UnmarshalJSON(data []byte) error
- func (r *InterfaceMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type KernelParam
- type KernelParamMap
- func (r KernelParamMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*KernelParam, error)
- func (r KernelParamMap) AppendSysResourceIfExists(sr string, sys *system.System) (*KernelParam, system.KernelParam, bool)
- func (r *KernelParamMap) UnmarshalJSON(data []byte) error
- func (r *KernelParamMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Mount
- type MountMap
- func (r MountMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Mount, error)
- func (r MountMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Mount, system.Mount, bool)
- func (r *MountMap) UnmarshalJSON(data []byte) error
- func (r *MountMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Package
- type PackageMap
- func (r PackageMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Package, error)
- func (r PackageMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Package, system.Package, bool)
- func (r *PackageMap) UnmarshalJSON(data []byte) error
- func (r *PackageMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Port
- type PortMap
- func (r PortMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Port, error)
- func (r PortMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Port, system.Port, bool)
- func (r *PortMap) UnmarshalJSON(data []byte) error
- func (r *PortMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Process
- type ProcessMap
- func (r ProcessMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Process, error)
- func (r ProcessMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Process, system.Process, bool)
- func (r *ProcessMap) UnmarshalJSON(data []byte) error
- func (r *ProcessMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type Resource
- type ResourceRead
- type Service
- type ServiceMap
- func (r ServiceMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*Service, error)
- func (r ServiceMap) AppendSysResourceIfExists(sr string, sys *system.System) (*Service, system.Service, bool)
- func (r *ServiceMap) UnmarshalJSON(data []byte) error
- func (r *ServiceMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
- type TestResult
- type User
- type UserMap
- func (r UserMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*User, error)
- func (r UserMap) AppendSysResourceIfExists(sr string, sys *system.System) (*User, system.User, bool)
- func (r *UserMap) UnmarshalJSON(data []byte) error
- func (r *UserMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
Constants ¶
const ( Value = iota Values Contains )
const ( SUCCESS = iota FAIL SKIP )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Addr ¶
type Addr struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Address string `json:"-" yaml:"-"` Reachable matcher `json:"reachable" yaml:"reachable"` Timeout int `json:"timeout" yaml:"timeout"` }
type AddrMap ¶ added in v0.0.4
func (AddrMap) AppendSysResource ¶ added in v0.0.4
func (AddrMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*AddrMap) UnmarshalJSON ¶ added in v0.0.4
func (*AddrMap) UnmarshalYAML ¶ added in v0.1.0
func (r *AddrMap) UnmarshalYAML(data []byte) error {
type Command ¶
type Command struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Command string `json:"-" yaml:"-"` ExitStatus matcher `json:"exit-status" yaml:"exit-status"` Stdout []string `json:"stdout" yaml:"stdout"` Stderr []string `json:"stderr" yaml:"stderr"` Timeout int `json:"timeout" yaml:"timeout"` }
type CommandMap ¶ added in v0.0.4
func (CommandMap) AppendSysResource ¶ added in v0.0.4
func (CommandMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*CommandMap) UnmarshalJSON ¶ added in v0.0.4
func (r *CommandMap) UnmarshalJSON(data []byte) error
func (*CommandMap) UnmarshalYAML ¶ added in v0.1.0
func (r *CommandMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *CommandMap) UnmarshalYAML(data []byte) error {
type DNS ¶
type DNS struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Host string `json:"-" yaml:"-"` Resolveable matcher `json:"resolveable" yaml:"resolveable"` Addrs matcher `json:"addrs,omitempty" yaml:"addrs,omitempty"` Timeout int `json:"timeout" yaml:"timeout"` Server string `json:"server,omitempty" yaml:"server,omitempty"` }
type DNSMap ¶ added in v0.0.4
func (DNSMap) AppendSysResource ¶ added in v0.0.4
func (DNSMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*DNSMap) UnmarshalJSON ¶ added in v0.0.4
func (*DNSMap) UnmarshalYAML ¶ added in v0.1.0
func (r *DNSMap) UnmarshalYAML(data []byte) error {
type File ¶
type File struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Path string `json:"-" yaml:"-"` Exists matcher `json:"exists" yaml:"exists"` Mode matcher `json:"mode,omitempty" yaml:"mode,omitempty"` Size matcher `json:"size,omitempty" yaml:"size,omitempty"` Owner matcher `json:"owner,omitempty" yaml:"owner,omitempty"` Group matcher `json:"group,omitempty" yaml:"group,omitempty"` LinkedTo matcher `json:"linked-to,omitempty" yaml:"linked-to,omitempty"` Filetype matcher `json:"filetype,omitempty" yaml:"filetype,omitempty"` Contains []string `json:"contains" yaml:"contains"` Md5 matcher `json:"md5,omitempty" yaml:"md5,omitempty"` }
type FileMap ¶ added in v0.0.4
func (FileMap) AppendSysResource ¶ added in v0.0.4
func (FileMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*FileMap) UnmarshalJSON ¶ added in v0.0.4
func (*FileMap) UnmarshalYAML ¶ added in v0.1.0
func (r *FileMap) UnmarshalYAML(data []byte) error {
type Gossfile ¶
type Gossfile struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Path string `json:"-" yaml:"-"` }
func NewGossfile ¶
type GossfileMap ¶ added in v0.0.4
func (GossfileMap) AppendSysResource ¶ added in v0.0.4
func (GossfileMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*GossfileMap) UnmarshalJSON ¶ added in v0.0.4
func (r *GossfileMap) UnmarshalJSON(data []byte) error
func (*GossfileMap) UnmarshalYAML ¶ added in v0.1.0
func (r *GossfileMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *GossfileMap) UnmarshalYAML(data []byte) error {
type Group ¶
type GroupMap ¶ added in v0.0.4
func (GroupMap) AppendSysResource ¶ added in v0.0.4
func (GroupMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*GroupMap) UnmarshalJSON ¶ added in v0.0.4
func (*GroupMap) UnmarshalYAML ¶ added in v0.1.0
func (r *GroupMap) UnmarshalYAML(data []byte) error {
type HTTP ¶ added in v0.1.10
type HTTP struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` HTTP string `json:"-" yaml:"-"` Status matcher `json:"status" yaml:"status"` AllowInsecure bool `json:"allow-insecure" yaml:"allow-insecure"` NoFollowRedirects bool `json:"no-follow-redirects" yaml:"no-follow-redirects"` Timeout int `json:"timeout" yaml:"timeout"` Body []string `json:"body" yaml:"body"` }
type HTTPMap ¶ added in v0.1.10
func (HTTPMap) AppendSysResource ¶ added in v0.1.10
func (HTTPMap) AppendSysResourceIfExists ¶ added in v0.1.10
func (*HTTPMap) UnmarshalJSON ¶ added in v0.1.10
func (*HTTPMap) UnmarshalYAML ¶ added in v0.1.10
func (r *HTTPMap) UnmarshalYAML(data []byte) error {
type Interface ¶ added in v0.1.8
type Interface struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Name string `json:"-" yaml:"-"` Exists matcher `json:"exists" yaml:"exists"` Addrs matcher `json:"addrs,omitempty" yaml:"addrs,omitempty"` }
func NewInterface ¶ added in v0.1.8
type InterfaceMap ¶ added in v0.1.8
func (InterfaceMap) AppendSysResource ¶ added in v0.1.8
func (InterfaceMap) AppendSysResourceIfExists ¶ added in v0.1.8
func (*InterfaceMap) UnmarshalJSON ¶ added in v0.1.8
func (r *InterfaceMap) UnmarshalJSON(data []byte) error
func (*InterfaceMap) UnmarshalYAML ¶ added in v0.1.8
func (r *InterfaceMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *InterfaceMap) UnmarshalYAML(data []byte) error {
type KernelParam ¶ added in v0.1.8
type KernelParam struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Key string `json:"-" yaml:"-"` Value matcher `json:"value" yaml:"value"` }
func NewKernelParam ¶ added in v0.1.8
func NewKernelParam(sysKernelParam system.KernelParam, config util.Config) (*KernelParam, error)
func (*KernelParam) GetMeta ¶ added in v0.1.8
func (r *KernelParam) GetMeta() meta
func (*KernelParam) GetTitle ¶ added in v0.1.8
func (r *KernelParam) GetTitle() string
FIXME: Can this be refactored?
func (*KernelParam) ID ¶ added in v0.1.8
func (a *KernelParam) ID() string
func (*KernelParam) SetID ¶ added in v0.1.8
func (a *KernelParam) SetID(id string)
func (*KernelParam) Validate ¶ added in v0.1.8
func (a *KernelParam) Validate(sys *system.System) []TestResult
type KernelParamMap ¶ added in v0.1.8
type KernelParamMap map[string]*KernelParam
func (KernelParamMap) AppendSysResource ¶ added in v0.1.8
func (r KernelParamMap) AppendSysResource(sr string, sys *system.System, config util.Config) (*KernelParam, error)
func (KernelParamMap) AppendSysResourceIfExists ¶ added in v0.1.8
func (r KernelParamMap) AppendSysResourceIfExists(sr string, sys *system.System) (*KernelParam, system.KernelParam, bool)
func (*KernelParamMap) UnmarshalJSON ¶ added in v0.1.8
func (r *KernelParamMap) UnmarshalJSON(data []byte) error
func (*KernelParamMap) UnmarshalYAML ¶ added in v0.1.8
func (r *KernelParamMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *KernelParamMap) UnmarshalYAML(data []byte) error {
type Mount ¶ added in v0.1.8
type Mount struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` MountPoint string `json:"-" yaml:"-"` Exists matcher `json:"exists" yaml:"exists"` Opts matcher `json:"opts,omitempty" yaml:"opts,omitempty"` Source matcher `json:"source,omitempty" yaml:"source,omitempty"` Filesystem matcher `json:"filesystem,omitempty" yaml:"filesystem,omitempty"` }
type MountMap ¶ added in v0.1.8
func (MountMap) AppendSysResource ¶ added in v0.1.8
func (MountMap) AppendSysResourceIfExists ¶ added in v0.1.8
func (*MountMap) UnmarshalJSON ¶ added in v0.1.8
func (*MountMap) UnmarshalYAML ¶ added in v0.1.8
func (r *MountMap) UnmarshalYAML(data []byte) error {
type Package ¶
type PackageMap ¶ added in v0.0.4
func (PackageMap) AppendSysResource ¶ added in v0.0.4
func (PackageMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*PackageMap) UnmarshalJSON ¶ added in v0.0.4
func (r *PackageMap) UnmarshalJSON(data []byte) error
func (*PackageMap) UnmarshalYAML ¶ added in v0.1.0
func (r *PackageMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *PackageMap) UnmarshalYAML(data []byte) error {
type Port ¶
type PortMap ¶ added in v0.0.4
func (PortMap) AppendSysResource ¶ added in v0.0.4
func (PortMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*PortMap) UnmarshalJSON ¶ added in v0.0.4
func (*PortMap) UnmarshalYAML ¶ added in v0.1.0
func (r *PortMap) UnmarshalYAML(data []byte) error {
type Process ¶
type ProcessMap ¶ added in v0.0.4
func (ProcessMap) AppendSysResource ¶ added in v0.0.4
func (ProcessMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*ProcessMap) UnmarshalJSON ¶ added in v0.0.4
func (r *ProcessMap) UnmarshalJSON(data []byte) error
func (*ProcessMap) UnmarshalYAML ¶ added in v0.1.0
func (r *ProcessMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *ProcessMap) UnmarshalYAML(data []byte) error {
type ResourceRead ¶ added in v0.1.1
type Service ¶
type ServiceMap ¶ added in v0.0.4
func (ServiceMap) AppendSysResource ¶ added in v0.0.4
func (ServiceMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*ServiceMap) UnmarshalJSON ¶ added in v0.0.4
func (r *ServiceMap) UnmarshalJSON(data []byte) error
func (*ServiceMap) UnmarshalYAML ¶ added in v0.1.0
func (r *ServiceMap) UnmarshalYAML(unmarshal func(v interface{}) error) error
func (r *ServiceMap) UnmarshalYAML(data []byte) error {
type TestResult ¶
type TestResult struct { Successful bool `json:"successful" yaml:"successful"` ResourceId string `json:"resource-id" yaml:"resource-id"` ResourceType string `json:"resource-type" yaml:"resource-type"` Title string `json:"title" yaml:"title"` Meta meta `json:"meta" yaml:"meta"` TestType int `json:"test-type" yaml:"test-type"` Result int `json:"result" yaml:"result"` Property string `json:"property" yaml:"property"` Err error `json:"err" yaml:"err"` Expected []string `json:"expected" yaml:"expected"` Found []string `json:"found" yaml:"found"` Human string `json:"human" yaml:"human"` Duration time.Duration `json:"duration" yaml:"duration"` }
func ValidateContains ¶
func ValidateContains(res ResourceRead, property string, expectedValues []string, method func() (io.Reader, error), skip bool) TestResult
func ValidateValue ¶
func ValidateValue(res ResourceRead, property string, expectedValue interface{}, actual interface{}, skip bool) TestResult
type User ¶
type User struct { Title string `json:"title,omitempty" yaml:"title,omitempty"` Meta meta `json:"meta,omitempty" yaml:"meta,omitempty"` Username string `json:"-" yaml:"-"` Exists matcher `json:"exists" yaml:"exists"` UID matcher `json:"uid,omitempty" yaml:"uid,omitempty"` GID matcher `json:"gid,omitempty" yaml:"gid,omitempty"` Groups matcher `json:"groups,omitempty" yaml:"groups,omitempty"` Home matcher `json:"home,omitempty" yaml:"home,omitempty"` Shell matcher `json:"shell,omitempty" yaml:"shell,omitempty"` }
type UserMap ¶ added in v0.0.4
func (UserMap) AppendSysResource ¶ added in v0.0.4
func (UserMap) AppendSysResourceIfExists ¶ added in v0.0.4
func (*UserMap) UnmarshalJSON ¶ added in v0.0.4
func (*UserMap) UnmarshalYAML ¶ added in v0.1.0
func (r *UserMap) UnmarshalYAML(data []byte) error {