patagia-control/agent/src/main.rs
Daniel Lundin 31c8921aca
All checks were successful
ci/woodpecker/pr/ci Pipeline was successful
Use trace-request for dropshot instrumentation
2024-12-17 10:19:29 +01:00

24 lines
568 B
Rust

use anyhow::Result;
use clap::Parser;
use tokio::time::{sleep, Duration};
mod patagia_api;
#[derive(Parser, Debug)]
#[command(version, about, long_about = None)]
struct Cli {}
#[tokio::main]
async fn main() -> Result<()> {
let _args = Cli::parse();
let _tracing = instrumentation::init_tracing_subscriber()?;
tracing::info!("Patagia Agent");
let client = patagia_api::Client::new("http://localhost:9474");
let result = client.version().await?;
tracing::info!("Result: {:?}", result);
sleep(Duration::from_secs(3)).await;
Ok(())
}