github.com/haraldfw/cfger (go): Package cfger provides functions to read configuration files in raw, JSON or YAML format from a file or environment variable. And additionally a shortcut to read docker-secrets. It also follows configuration locations in env-vars if the value has a valid prefix.  Valid prefixes are:  ReadCfg(val) wraps ReadStructuredCfg(val, nil), which results in a raw read. So if val here resolves to a JSON-file it returns the contents of the JSON-file as a string, without unmarshalling  For cfger to unmarshal the file, you need to supply a valid interface in the form defined in the documentation for the package https://golang.org/pkg/encoding/json/#Unmarshal. Similarly for YAML-unmarshalling you have to supply a valid interface as described in the https://godoc.org/gopkg.in/yaml.v3#Unmarshal documentation.
Keywords: docker|docker-secrets|go|golang|golang-configuration