vaultinjector

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindInlineVaultDelimiters

func FindInlineVaultDelimiters(value string) [][]string

func HasInlineVaultDelimiters

func HasInlineVaultDelimiters(value string) bool

Types

type Config

type Config struct {
	TransitKeyID         string
	TransitPath          string
	TransitBatchSize     int
	IgnoreMissingSecrets bool
	DaemonMode           bool
}

type SecretInjector

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

func NewSecretInjector

func NewSecretInjector(config Config, client *vault.Client, renewer SecretRenewer, logger *slog.Logger) SecretInjector

func (*SecretInjector) FetchTransitSecrets

func (i *SecretInjector) FetchTransitSecrets(secrets []string) (map[string][]byte, error)

func (*SecretInjector) GetDataFromVault

func (i *SecretInjector) GetDataFromVault(data map[string]string) (map[string]string, error)

func (*SecretInjector) InjectSecretsFromVault

func (i *SecretInjector) InjectSecretsFromVault(references map[string]string, inject SecretInjectorFunc) error

func (*SecretInjector) InjectSecretsFromVaultPath

func (i *SecretInjector) InjectSecretsFromVaultPath(paths string, inject SecretInjectorFunc) error

type SecretInjectorFunc

type SecretInjectorFunc func(key, value string)

type SecretRenewer

type SecretRenewer interface {
	Renew(path string, secret *vaultapi.Secret) error
}

Jump to

Keyboard shortcuts

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