Documentation
¶
Overview ¶
Package gcpsecretfetch is a utility library for getting secrets from GCP Secret Manager.
Package gcpsecretfetch is a utility library for getting secrets from GCP Secret Manager.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitializeConfig ¶
func InitializeConfig(cfg interface{}, project string, opts ...ConfigOption) error
InitializeConfig initializes a config struct by getting the secrets from GCP Secret Manager
This function works by reflecting on the fields in the passed pointer struct, and then dispatching calls to get the secret payloads from GCP for the corresponding secrets. The function must be passed a pointer to an arbitrary config struct, and the config struct must only have string fields.
func UpdateSecrets ¶
func UpdateSecrets(project string, secrets map[string]string, opts ...ConfigOption) error
Types ¶
type ConfigOption ¶
type ConfigOption func(client *secretClient)
func WithConcurrency ¶
func WithConcurrency(n int) ConfigOption
func WithDisablePrior ¶ added in v1.0.1
func WithDisablePrior() ConfigOption
func WithViper ¶
func WithViper(v *viper.Viper) ConfigOption
Click to show internal directories.
Click to hide internal directories.