vault

package
v0.0.0-rc.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Enabled bool `yaml:"enabled"`

	URL       string `yaml:"url"`
	Token     string `yaml:"token"`
	MountPath string `yaml:"mount_path"`
}

func (*Config) RegisterFlags

func (cfg *Config) RegisterFlags(fs *flag.FlagSet)

func (*Config) Validate

func (cfg *Config) Validate() error

type SecretsEngine

type SecretsEngine interface {
	Get(ctx context.Context, path string) (*hashivault.KVSecret, error)
}

SecretsEngine Vault Secrets Engine

type Vault

type Vault struct {
	KVStore SecretsEngine
}

func New

func New(cfg Config) (*Vault, error)

func (*Vault) ReadSecret

func (v *Vault) ReadSecret(path string) ([]byte, error)

Jump to

Keyboard shortcuts

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