Documentation ¶
Overview ¶
Package secretbackends provides the api client for the secretbackends facade.
Index ¶
- type Client
- func (c *Client) GetBackendConfigForDrain(ctx context.Context, backendID *string) (*provider.ModelBackendConfig, string, error)
- func (c *Client) GetContentInfo(ctx context.Context, uri *coresecrets.URI, label string, refresh, peek bool) (*secrets.ContentParams, *provider.ModelBackendConfig, bool, error)
- func (c *Client) GetRevisionContentInfo(ctx context.Context, uri *coresecrets.URI, revision int, pendingDelete bool) (*secrets.ContentParams, *provider.ModelBackendConfig, bool, error)
- func (c *Client) GetSecretBackendConfig(ctx context.Context, backendID *string) (*provider.ModelBackendConfigInfo, error)
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 the api client for accessing secret backend related facades.
func NewClient ¶
func NewClient(facade base.FacadeCaller) *Client
NewClient creates a secrets api client.
func (*Client) GetBackendConfigForDrain ¶
func (c *Client) GetBackendConfigForDrain(ctx context.Context, backendID *string) (*provider.ModelBackendConfig, string, error)
GetBackendConfigForDrain fetches the config needed to make a secret backend client for the drain worker.
func (*Client) GetContentInfo ¶
func (c *Client) GetContentInfo(ctx context.Context, uri *coresecrets.URI, label string, refresh, peek bool) (*secrets.ContentParams, *provider.ModelBackendConfig, bool, error)
GetContentInfo returns info about the content of a secret.
func (*Client) GetRevisionContentInfo ¶
func (c *Client) GetRevisionContentInfo(ctx context.Context, uri *coresecrets.URI, revision int, pendingDelete bool) (*secrets.ContentParams, *provider.ModelBackendConfig, bool, error)
GetRevisionContentInfo returns info about the content of a secret revision. If pendingDelete is true, the revision is marked for deletion.
func (*Client) GetSecretBackendConfig ¶
func (c *Client) GetSecretBackendConfig(ctx context.Context, backendID *string) (*provider.ModelBackendConfigInfo, error)
GetSecretBackendConfig fetches the config needed to make a secret backend client. If backendID is nil, fetch the current active backend config.