Documentation
¶
Overview ¶
Package datasource resolves a values/store file reference (FileRef.Src) into bytes. Nothing more: merging of multiple values files is left to nelm (Helm-native ordered merge), so this package only turns a reference into content.
Local paths (schemeless or file://) are read straight from disk, relative to the resolver's base directory. Every other scheme (env:, http(s)://, s3://, vault://, git://, ...) is read through gomplate v5's `include`, which returns the raw datasource content. The content is then post-processed by extension: *.sops is decrypted, *.tpl/*.tmpl are rendered as gomplate templates, and everything else is copied verbatim. The two compose: *.tpl.sops is decrypted first, then rendered.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsEncrypted ¶
IsEncrypted reports whether src is a sops source, i.e. whether resolving it writes decrypted content to disk. Callers use it to warn about what ends up in the build directory.
Types ¶
type Resolver ¶
type Resolver struct {
// BaseDir is the directory schemeless (local) paths resolve against.
BaseDir string
}
Resolver reads datasource references relative to a base directory.
func NewResolver ¶
NewResolver returns a Resolver rooted at baseDir.