Documentation ¶
Index ¶
- type Client
- func (c *Client) CreateApp(ctx context.Context, app *kdeploypb.AppInput) (*kdeploypb.App, error)
- func (c *Client) CreateTask(ctx context.Context, app *kdeploypb.TaskInput) (*kdeploypb.Task, error)
- func (c *Client) DeleteAll(ctx context.Context, namespace *kdeploypb.Namespace) error
- func (c *Client) DeleteApp(ctx context.Context, ref *kdeploypb.Ref) error
- func (c *Client) DeleteTask(ctx context.Context, ref *kdeploypb.Ref) error
- func (c *Client) GetApp(ctx context.Context, ref *kdeploypb.Ref) (*kdeploypb.App, error)
- func (c *Client) GetTask(ctx context.Context, ref *kdeploypb.Ref) (*kdeploypb.Task, error)
- func (c *Client) StreamLogs(ctx context.Context, ref *kdeploypb.Ref, fn func(l *kdeploypb.Log) bool) error
- func (c *Client) UpdateApp(ctx context.Context, app *kdeploypb.AppInput) (*kdeploypb.App, error)
- func (c *Client) UpdateTask(ctx context.Context, app *kdeploypb.TaskInput) (*kdeploypb.Task, error)
- type Opt
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a kdeploy gRPC client
func (*Client) CreateTask ¶ added in v0.0.1
CreateTask creates a new task
func (*Client) DeleteAll ¶ added in v0.0.1
DeleteApp deletes all tasks/applications in the namespace
func (*Client) DeleteTask ¶ added in v0.0.1
DeleteTask deletes a task by reference(name/namespace)
func (*Client) StreamLogs ¶ added in v0.0.4
func (c *Client) StreamLogs(ctx context.Context, ref *kdeploypb.Ref, fn func(l *kdeploypb.Log) bool) error
StreamLogs streams logs from an application until the context cancelled or the function(fn) return false
type Opt ¶
type Opt func(o *Options)
Opt is a single configuration option
func WithLogging ¶
WithLogging registers a logging middleware
func WithTokenSource ¶
func WithTokenSource(tokenSource oauth2.TokenSource) Opt
WithTokenSource uses oauth token add an authorization header to every outbound request
func WithTransportCreds ¶
func WithTransportCreds(creds credentials.TransportCredentials) Opt
WithTransportCreds adds transport credentials to the client
Click to show internal directories.
Click to hide internal directories.