vault

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrSecretNotFound = errors.New("no secret not found at given path")
)

Functions

This section is empty.

Types

type VaultClient

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

VaultClient is used to connect to the Vault API and stores a k/v engine version (either v1 or v2)

func NewVaultClient

func NewVaultClient(engine string) (*VaultClient, error)

NewVaultClient instantiates a new client to communicate with Vault. It uses the DefaultConfig functionality, which sets the VAULT_ADDR == localhost:8200 unless the environment variable is set in the user's dev environment

func (*VaultClient) SearchPath

func (v *VaultClient) SearchPath(path, secret string) error

SearchPath loops over a given Vault path and searches for the secret inside this path.

Jump to

Keyboard shortcuts

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