Skip to content

server: support bootstrap YAML include/glob#43973

Open
garimauttam wants to merge 3 commits intoenvoyproxy:mainfrom
garimauttam:issue-43511-multifile-bootstrap-include
Open

server: support bootstrap YAML include/glob#43973
garimauttam wants to merge 3 commits intoenvoyproxy:mainfrom
garimauttam:issue-43511-multifile-bootstrap-include

Conversation

@garimauttam
Copy link
Contributor

Implements top-level YAML include support for bootstrap configs.

  • Allows include to reference a file, directory, or wildcard pattern (e.g. conf.d/*.yaml), with recursive expansion.
  • Adds include-cycle detection using normalized paths to prevent loops.
  • Updates --config-path help text and adds focused coverage in test/server/bootstrap_config_dir_test.cc.

Fixes #43511.

When --config-path is a directory, load and merge YAML files in lexical order.

Signed-off-by: garima-uttam <garimauttam@ibm.com>
Allow a top-level "include" key in YAML bootstrap files to pull in other YAML fragments (file/dir/glob), with recursive expansion and cycle detection.

Signed-off-by: garima-uttam <garimauttam@ibm.com>
@paul-r-gall
Copy link
Contributor

CI failures look relevant.

}

absl::StatusOr<std::vector<std::string>>
expandIncludePath(const std::string& include_path, const std::string& including_file_path,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

expandIncludePath resolves includes to absolute paths but never validates they're within a safe base directory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Native multi-file YAML config support like Nginx include directive

3 participants