Cut over public engine construction to ConfigKit sources

This commit is contained in:
2026-09-30 03:18:49 +00:00
parent 17b6c7bca5
commit ba9c972faa
37 changed files with 1653 additions and 1423 deletions

View File

@@ -12,8 +12,10 @@ import (
)
// DirectoryInputs selects the YAML files beneath an explicitly chosen host
// directory as one strict-composition tier. The returned order is deterministic;
// it does not assign precedence among those files.
// directory as one strict-composition group. The returned order is deterministic;
// it does not assign precedence among those files. Discovery is recursive over
// .yaml and .yml files. An unavailable root fails; an empty directory yields
// no inputs. Imports are disabled unless callers enable them on the inputs.
func DirectoryInputs(directory string) ([]configkit.Input, error) {
root, err := filepath.Abs(directory)
if err != nil {
@@ -45,8 +47,11 @@ func DirectoryInputs(directory string) ([]configkit.Input, error) {
}
// FilesystemInputs selects the YAML files beneath root in a caller-owned
// filesystem as one strict-composition tier. The caller retains ownership of
// the filesystem; imports remain disabled unless callers enable them on inputs.
// filesystem as one strict-composition group. Discovery is recursive over
// .yaml and .yml files, with deterministic ordering and no precedence among
// files. The caller retains ownership of the filesystem; an unavailable root
// fails and an empty directory yields no inputs. Imports remain disabled unless
// callers enable them on inputs.
func FilesystemInputs(label string, filesystem fs.FS, root string) ([]configkit.Input, error) {
if filesystem == nil {
return nil, fmt.Errorf("configuration filesystem is nil")