Files
harmony/examples/okd_system_reserved/src/main.rs
Sylvain Tremblay 9e46b94e9b
All checks were successful
Run Check Script / check (pull_request) Successful in 2m23s
feat: add example for okd_system_reserved
2026-04-15 07:26:32 -04:00

26 lines
574 B
Rust

use harmony::{
inventory::Inventory,
modules::okd::system_reserved_score::{MachineConfigPool, SystemReservedScore},
topology::K8sAnywhereTopology,
};
#[tokio::main]
async fn main() {
harmony_cli::cli_logger::init();
let master_score = SystemReservedScore {
pool: MachineConfigPool::Master,
memory: "0.5Gi".to_string(),
..Default::default()
};
harmony_cli::run(
Inventory::autoload(),
K8sAnywhereTopology::from_env(),
vec![Box::new(master_score)],
None,
)
.await
.unwrap();
}