Clarify search and secret bootstrap names
This commit is contained in:
13
secrets.go
13
secrets.go
@@ -8,7 +8,7 @@ import (
|
||||
)
|
||||
|
||||
// SecretFileStatus describes the outcome for one file considered by
|
||||
// LoadSecretsDir.
|
||||
// LoadSecretsIntoEnvironment.
|
||||
type SecretFileStatus string
|
||||
|
||||
const (
|
||||
@@ -85,11 +85,12 @@ func (e *SecretsError) Diagnostics() []Diagnostic {
|
||||
return result
|
||||
}
|
||||
|
||||
// LoadSecretsDir explicitly loads immediate regular files from directory into
|
||||
// previously unset process environment variables. Applications should call it
|
||||
// once during startup, before concurrent work; Load never calls it.
|
||||
// Dot-prefixed entries are ignored and omitted from the report.
|
||||
func LoadSecretsDir(directory string) (*SecretsReport, error) {
|
||||
// LoadSecretsIntoEnvironment explicitly loads immediate regular files into the
|
||||
// process environment, preserving variables that are already set, including
|
||||
// empty values. Dot-prefixed entries are ignored and omitted from the report.
|
||||
// Load never calls it. The report accompanies any error, and an error does not
|
||||
// roll back values already applied.
|
||||
func LoadSecretsIntoEnvironment(directory string) (*SecretsReport, error) {
|
||||
report, err := engine.LoadSecretsDir(directory)
|
||||
result := &SecretsReport{value: report}
|
||||
if err == nil {
|
||||
|
||||
Reference in New Issue
Block a user