Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvictToSemaKey ¶
ConvictToSemaKey translates the name to something that is appropriate for SeMa storage
Types ¶
type CatchAllResolver ¶
type CatchAllResolver struct{}
CatchAllResolver is a mock implementation
func (CatchAllResolver) GetClient ¶
func (CatchAllResolver) GetClient() secretmanager.KVClient
func (CatchAllResolver) IsVerbose ¶
func (CatchAllResolver) IsVerbose() bool
func (CatchAllResolver) Resolve ¶
func (CatchAllResolver) Resolve(schema ConvictConfigSchema) map[string]handlers.ResolvedSecret
type ConvictConfigSchema ¶
type ConvictConfigSchema struct { Tree *ConvictJSONTree FlatConfigurations []ConvictConfiguration // contains filtered or unexported fields }
ConvictConfigSchema -
func ParseSchemaFile ¶
func ParseSchemaFile(schemaFile string) ConvictConfigSchema
ParseSchemaFile -
type ConvictConfiguration ¶
type ConvictConfiguration struct { Path []string Format convictFormat DefaultValue interface{} `json:"default"` Doc string `json:"doc"` Env string `json:"env"` Optional bool }
ConvictConfiguration -
func (*ConvictConfiguration) Key ¶
func (conf *ConvictConfiguration) Key() string
Key is the standardized way of serializing a ConvictConfiguration.Path
type ConvictJSONTree ¶
type ConvictJSONTree struct { Leaf *ConvictConfiguration Children map[string]*ConvictJSONTree }
ConvictJSONTree -
func (*ConvictJSONTree) Nest ¶
func (tree *ConvictJSONTree) Nest(key string)
func (*ConvictJSONTree) UnmarshalJSON ¶
func (tree *ConvictJSONTree) UnmarshalJSON(data []byte) error
type Matcher ¶
type Matcher = func(ConvictConfiguration, secretmanager.KVValue, string) bool
Matcher -
var DefaultMatcher Matcher = func(c ConvictConfiguration, s secretmanager.KVValue, key string) bool {
return s.GetShortName() == key
}
DefaultMatcher matches the secret with the key based on the SecretManager short-name
type SchemaResolver ¶
type SchemaResolver interface { Resolve(schema ConvictConfigSchema) map[string]handlers.ResolvedSecret IsVerbose() bool GetClient() secretmanager.KVClient }
SchemaResolver -
func MakeSchemaResolver ¶
func MakeSchemaResolver(client secretmanager.KVClient, prefix string, verbose bool, matcher Matcher) SchemaResolver
MakeSchemaResolver -
Click to show internal directories.
Click to hide internal directories.