secrets

package
v0.9.1-rc.2 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2023 License: Apache-2.0 Imports: 7 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SecretStoreProviders = NewProviders()

Functions

This section is empty.

Types

type Providers

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

func NewProviders

func NewProviders() *Providers

func (*Providers) GetProviderByName

func (ps *Providers) GetProviderByName(providerName string) (SecretStoreFactory, bool)

GetProviderByName returns registered provider by name.

func (*Providers) Register

func (ps *Providers) Register(ssf SecretStoreFactory, spec *secrets.ProviderSpec)

Register registers a provider with associated spec. This is expected to happen during app startup.

type SecretStore

type SecretStore interface {
	// GetSecret retrieves ref secret from various cloud secret manager.
	GetSecret(ctx context.Context, ref secretsapi.ExternalSecretRef) ([]byte, error)
}

SecretStore provides the interface to interact with various cloud secret manager.

type SecretStoreFactory

type SecretStoreFactory interface {
	// NewSecretStore constructs a usable secret store with specific provider spec.
	NewSecretStore(spec secretsapi.SecretStoreSpec) (SecretStore, error)
}

SecretStoreFactory is a factory type for secret store.

Directories

Path Synopsis
providers

Jump to

Keyboard shortcuts

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