projectsyn / reclass-rs

Reimplementation of https://github.com/kapicorp/reclass in Rust with Python bindings through PyO3.
BSD 3-Clause "New" or "Revised" License
7 stars 0 forks source link

Add support for loading config from a file #92

Closed simu closed 7 months ago

simu commented 7 months ago

Kapitan allows users to provide additional reclass config options in a file reclass-config.yml in the inventory root directory. We add this feature to reclass-rs, but allow users to specify an arbitrary YAML file from which config options are loaded.

Additionally, we update the inventory_tests::test_render() Rust and the test_inventory() Python test cases to load the config from the already existing reclass-config.yml for the test inventory.

This PR is split out from #84

Checklist

github-actions[bot] commented 7 months ago

Benchmark for cb0c952

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | Reclass::inventory() multi-threaded | 1609.8±108.40µs | 1612.4±134.00µs | +0.16% | | Reclass::inventory() single-threaded | 3.6±0.11ms | **3.5±0.04ms** | **-2.78%** |
github-actions[bot] commented 7 months ago

Benchmark for f58ee74

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | Reclass::inventory() multi-threaded | 1652.3±116.28µs | 1596.8±59.52µs | -3.36% | | Reclass::inventory() single-threaded | 3.7±0.21ms | **3.6±0.09ms** | **-2.70%** |
github-actions[bot] commented 7 months ago

Benchmark for 0a35f51

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | Reclass::inventory() multi-threaded | 1600.7±117.09µs | 1588.5±90.37µs | -0.76% | | Reclass::inventory() single-threaded | 3.6±0.09ms | 3.6±0.03ms | 0.00% |