Versions in this module Expand all Collapse all v0 v0.0.2 Feb 8, 2020 v0.0.1 Feb 8, 2020 Changes in this version + const Compound + const Glob + const Grain + const GrainPCRE + const IPCIDR + const List + const LocalClient + const NodeGroup + const PCRE + const Pillar + const PillarPCRE + const Range + const RunnerClient + const WheelClient + var ErrorInvalidCredentials = errors.New("invalid credentials or authentication backend: %s") + var ErrorJobNotFound = errors.New("job was not found") + var ErrorKeyPairBroken = errors.New("cannot extract keypair from archive") + var ErrorKeyPairNotReceived = errors.New("public or private key was not received") + var ErrorMinionKeyNotFound = errors.New("minion key was not found") + var ErrorMinionNotFound = errors.New("minion not found") + var ErrorNotAuthenticated = errors.New("not authenticated") + type AsyncMinionJobResult struct + ID string + Minions []string + type Client struct + Address string + Token string + func NewClient(address string, username string, password string, backend string, ...) *Client + func (c *Client) GenerateKeyPair(ctx context.Context, id string, keySize int, force bool) (*MinionKeyPair, error) + func (c *Client) Hook(ctx context.Context, id string, data interface{}) error + func (c *Client) Job(ctx context.Context, id string) (*JobDetails, error) + func (c *Client) Jobs(ctx context.Context) ([]Job, error) + func (c *Client) Key(ctx context.Context, id string) (string, error) + func (c *Client) Keys(ctx context.Context) (*KeyResult, error) + func (c *Client) Login(ctx context.Context) error + func (c *Client) Logout(ctx context.Context) error + func (c *Client) Minion(ctx context.Context, id string) (*Minion, error) + func (c *Client) Minions(ctx context.Context) ([]Minion, error) + func (c *Client) RunCommand(ctx context.Context, cmd Command) (interface{}, error) + func (c *Client) RunCommands(ctx context.Context, cmds []Command) ([]interface{}, error) + func (c *Client) Stats(ctx context.Context) (map[string]interface{}, error) + func (c *Client) SubmitJob(ctx context.Context, job MinionJob) (*AsyncMinionJobResult, error) + func (c *Client) SubmitJobs(ctx context.Context, jobs []MinionJob) ([]AsyncMinionJobResult, error) + type Command struct + Arguments map[string]interface{} + Client CommandClient + Function string + Target Target + type CommandClient string + type ExpressionTarget struct + Expression string + Type TargetType + func (t ExpressionTarget) GetTarget() interface{} + func (t ExpressionTarget) GetType() TargetType + type Job struct + Arguments []interface{} + Function string + ID string + KWArguments map[string]interface{} + StartTime time.Time + Target Target + User string + type JobDetails struct + Minions []string + Returns map[string]interface{} + type KeyResult struct + Local []string + Minions []string + MinionsDenied []string + MinionsPre []string + MinionsRejected []string + type ListTarget struct + Targets []string + func (t ListTarget) GetTarget() interface{} + func (t ListTarget) GetType() TargetType + type Minion struct + Grains map[string]interface{} + ID string + type MinionJob struct + Arguments []interface{} + Function string + KWArguments map[string]interface{} + Target Target + type MinionKeyPair struct + ID string + Private string + Public string + type RequestError struct + Body []byte + Status string + StatusCode int + func (e *RequestError) Error() string + type Target interface + GetTarget func() interface{} + GetType func() TargetType + type TargetType string