Documentation
¶
Overview ¶
Package render resolves dotenv "ref+..." references into secret values.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Render ¶
Render scans a dotenv stream from r, resolves every full-value ref+/secretref+ reference through res in a single batch, splices the resolved values back into their exact source lines, and writes the byte-faithful result to w.
It is fail-closed: any failure (multiline reject, resolver error, emit failure, or residual-reference scan) returns an error and writes NOTHING to w. Nothing is ever written to w until the full output is buffered and every guard has passed. Per-backend credentials are the resolver's concern: vals surfaces its own auth errors uniformly, which Render propagates unchanged.
style selects how resolved values are quoted: dotenv.QuoteMinimal preserves the default byte-faithful output, dotenv.QuoteShell emits source-safe output.
Types ¶
type Resolver ¶
Resolver resolves a set of ref+ references to their secret values. Keyed by the dotenv KEY; each value is a full "ref+..." expression.
type ValsResolver ¶
type ValsResolver struct {
// contains filtered or unexported fields
}
ValsResolver resolves references through the helmfile/vals runtime.
func NewValsResolver ¶
func NewValsResolver() (*ValsResolver, error)
NewValsResolver constructs a fail-closed vals runtime. FailOnMissingKeyInMap ensures a missing fragment key (e.g. ref+doppler://p/c#/KEY) errors instead of silently resolving to nil.