Documentation
¶
Overview ¶
Package agent provides a gRPC client for agent services.
Index ¶
- type Client
- func (c *Client) Close() error
- func (c *Client) ReceiveKeyRequests(ctx context.Context, handler KeyRequestHandler) error
- func (c *Client) StreamFiles(ctx context.Context, rcvr *receiver.Receiver) error
- func (c *Client) SubmitHealthReports(ctx context.Context, reportChan <-chan health.Report) error
- func (c *Client) SubmitPublicKeys(ctx context.Context, publicKeys map[string]string) error
- type Config
- type KeyRequestHandler
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 handles authenticated access to the AgentService
func (*Client) ReceiveKeyRequests ¶
func (c *Client) ReceiveKeyRequests(ctx context.Context, handler KeyRequestHandler) error
ReceiveKeyRequests starts receiving key generation requests from the server
func (*Client) StreamFiles ¶
StreamFiles subscribes to server-sent files and writes them using the provided receiver.
func (*Client) SubmitHealthReports ¶
SubmitHealthReports maintains a persistent stream and sends reports periodically
type Config ¶
type Config struct {
ServerAddress string
ServerCACert x509.Certificate
ClientCert *x509.Certificate
PrivateKey crypto.PrivateKey
InstanceID string
}
Config holds the connection settings for the agent gRPC client
type KeyRequestHandler ¶
KeyRequestHandler is called when the server sends key generation requests
Click to show internal directories.
Click to hide internal directories.