Documentation
¶
Overview ¶
Package configyaml decodes YAML runtime configuration.
Index ¶
- func Decode(data []byte) (*config.Config, error)
- func DecodeSpec(data []byte) (*config.Spec, error)
- func Encode(cfg *config.Config) ([]byte, error)
- func EncodeSpec(spec *config.Spec) ([]byte, error)
- func Load(path string) (*config.Config, error)
- func LoadSpec(path string) (*config.Spec, *config.Config, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Decode ¶
Decode decodes a YAML configuration and resolves it: what it says, with its defaults filled in, validated.
func DecodeSpec ¶ added in v0.1.13
DecodeSpec decodes YAML into what it says, strictly (an unknown key fails) and canonically (see config.Spec.Canonical), without defaults or validation (see config.Resolve).
func Encode ¶ added in v0.1.11
Encode returns the encoding of a configuration in effect, every value written out: what `export` shows, and the form of payloads stored before Specs (they read back as Specs that set every value; see EncodeSpec).
func EncodeSpec ¶ added in v0.1.13
EncodeSpec returns the deterministic encoding of spec, what it sets only: the export encoding, and the payload of configuration store revisions.
Types ¶
This section is empty.