feat: Harmony inventory agent crate that exposes an endpoint listing the host hardware. Has to be reviewed, generated 99% by GLM-4.5 #115

Merged
johnride merged 4 commits from feat/inventory_agent into master 2025-08-19 16:58:05 +00:00
2 changed files with 2 additions and 2 deletions
Showing only changes of commit bc6f7336d2 - Show all commits

View File

@ -412,7 +412,7 @@ impl PhysicalHost {
}
fn get_host_uuid() -> String {
Self::read_dmi("system-uuid").unwrap_or_else(|| uuid::Uuid::new_v4().to_string())
Self::read_dmi("system-uuid").unwrap()
}
// Helper methods

View File

@ -17,7 +17,7 @@ async fn inventory() -> impl Responder {
async fn main() -> std::io::Result<()> {
env_logger::init();
let port = env::var("PORT").unwrap_or_else(|_| "8080".to_string());
let port = env::var("HARMONY_INVENTORY_AGENT_PORT").unwrap_or_else(|_| "8080".to_string());
let bind_addr = format!("0.0.0.0:{}", port);
log::info!("Starting inventory agent on {}", bind_addr);