client

package
v0.1.138 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2022 License: MIT Imports: 26 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	DefaultTimeout = 60 * time.Second
)

Variables

This section is empty.

Functions

func ValidateHandshake

func ValidateHandshake(h *plugin_go.Handshake) error

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(log logger.Logger, name, env string, cmd *exec.Cmd, hostAddr string, props map[string]interface{}, yamlContext YAMLContext) (*Client, error)

func (*Client) AcquireLocks added in v0.1.48

func (c *Client) AcquireLocks(ctx context.Context, props map[string]interface{}, lockNames []string, lockWait time.Duration, yamlContext *YAMLContext) (map[string]string, error)

func (*Client) Apply

func (c *Client) Apply(ctx context.Context, state *statefile.StateData, apps []*apiv1.AppPlan, deps []*apiv1.DependencyPlan, priority int, args map[string]interface{}, destroy bool, callback func(*apiv1.ApplyAction)) (*apiv1.ApplyDoneResponse, error)

func (*Client) ApplyDNS added in v0.1.107

func (c *Client) ApplyDNS(ctx context.Context, state *statefile.StateData, records []*apiv1.DNSRecord, args map[string]interface{}, destroy bool, callback func(*apiv1.ApplyAction)) (*apiv1.ApplyDNSDoneResponse, error)

func (*Client) ApplyMonitoring added in v0.1.123

func (c *Client) ApplyMonitoring(ctx context.Context, state *statefile.StateData, monitoring *apiv1.MonitoringData, args map[string]interface{}, destroy bool, callback func(*apiv1.ApplyAction)) (*apiv1.ApplyMonitoringDoneResponse, error)

func (*Client) Command added in v0.1.56

func (c *Client) Command(ctx context.Context, req *apiv1.CommandRequest) error

func (*Client) DeleteSecret added in v0.1.109

func (c *Client) DeleteSecret(ctx context.Context, key, typ string, props map[string]interface{}) (deleted bool, err error)

func (*Client) DeleteSecrets added in v0.1.109

func (c *Client) DeleteSecrets(ctx context.Context, typ string, props map[string]interface{}) error

func (*Client) DeployHook added in v0.1.107

func (c *Client) DeployHook(ctx context.Context, stage apiv1.DeployHookRequest_Stage, state *statefile.StateData, apps []*apiv1.AppPlan, deps []*apiv1.DependencyPlan, args map[string]interface{}, verify, destroy bool) (*apiv1.DeployHookResponse, error)

func (*Client) GetSecret added in v0.1.109

func (c *Client) GetSecret(ctx context.Context, key, typ string, props map[string]interface{}) (val string, ok bool, err error)

func (*Client) GetSecrets added in v0.1.109

func (c *Client) GetSecrets(ctx context.Context, typ string, props map[string]interface{}) (map[string]string, error)

func (*Client) GetState

func (c *Client) GetState(ctx context.Context, typ string, props map[string]interface{}, lock bool, lockWait time.Duration, skipCreate bool, yamlContext *YAMLContext) (ret *apiv1.GetStateResponse_State, err error)

func (*Client) Init

func (c *Client) Init(ctx context.Context) error

func (*Client) Logs added in v0.1.105

func (c *Client) Logs(ctx context.Context, req *apiv1.LogsRequest, callback func(*apiv1.LogsResponse)) error

func (*Client) Plan

func (c *Client) Plan(ctx context.Context, state *statefile.StateData, apps []*apiv1.AppPlan, deps []*apiv1.DependencyPlan, priority int, args map[string]interface{}, verify, destroy bool) (*apiv1.PlanResponse, error)

func (*Client) PlanDNS added in v0.1.107

func (c *Client) PlanDNS(ctx context.Context, state *statefile.StateData, records []*apiv1.DNSRecord, args map[string]interface{}, verify, destroy bool) (*apiv1.PlanDNSResponse, error)

func (*Client) PlanMonitoring added in v0.1.123

func (c *Client) PlanMonitoring(ctx context.Context, state *statefile.StateData, monitoring *apiv1.MonitoringData, args map[string]interface{}, verify, destroy bool) (*apiv1.PlanMonitoringResponse, error)

func (*Client) ProjectInit added in v0.1.21

func (c *Client) ProjectInit(ctx context.Context, name string, deployPlugins, runPlugins []string, dnsPlugin string, args map[string]interface{}) (*apiv1.ProjectInitResponse, error)

func (*Client) ReleaseLocks added in v0.1.48

func (c *Client) ReleaseLocks(ctx context.Context, props map[string]interface{}, locks map[string]string) error

func (*Client) ReleaseStateLock added in v0.1.47

func (c *Client) ReleaseStateLock(ctx context.Context, typ string, props map[string]interface{}, lockinfo string) error

func (*Client) ReplaceSecrets added in v0.1.109

func (c *Client) ReplaceSecrets(ctx context.Context, values map[string]string, typ string, props map[string]interface{}) error

func (*Client) Run added in v0.1.11

func (c *Client) Run(ctx context.Context, req *apiv1.RunRequest,
	outCh chan<- *apiv1.RunOutputResponse, errCh chan<- error) (*apiv1.RunStartResponse, error)

func (*Client) SaveState

func (c *Client) SaveState(ctx context.Context, state *statefile.StateData, typ string, props map[string]interface{}) (*apiv1.SaveStateResponse, error)

func (*Client) SetSecret added in v0.1.109

func (c *Client) SetSecret(ctx context.Context, key, value, typ string, props map[string]interface{}) (changed bool, err error)

func (*Client) Start

func (c *Client) Start(ctx context.Context) error

func (*Client) Stop

func (c *Client) Stop() error

type PluginError added in v0.1.2

type PluginError struct {
	// contains filtered or unexported fields
}

func (*PluginError) Error added in v0.1.2

func (e *PluginError) Error() string

func (*PluginError) Unwrap added in v0.1.2

func (e *PluginError) Unwrap() error

type YAMLContext

type YAMLContext struct {
	Prefix string
	Data   []byte
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL