feat(inventory_agent): use HARMONY_INVENTORY_AGENT_PORT as environment variable to set port
Some checks failed
Run Check Script / check (pull_request) Failing after 25s

This commit is contained in:
Jean-Gabriel Gill-Couture 2025-08-19 12:55:03 -04:00
parent 01da8631da
commit bc6f7336d2
2 changed files with 2 additions and 2 deletions

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);