add agent-host command for cli

This commit is contained in:
Connor Peet
2026-03-12 17:27:56 -07:00
parent 87b808097d
commit 222bbd480e
4 changed files with 388 additions and 1 deletions

View File

@@ -8,7 +8,7 @@ use std::process::Command;
use clap::Parser;
use cli::{
commands::{args, serve_web, tunnels, update, version, CommandContext},
commands::{agent_host, args, serve_web, tunnels, update, version, CommandContext},
constants::get_default_user_agent,
desktop, log,
state::LauncherPaths,
@@ -103,6 +103,10 @@ async fn main() -> Result<(), std::convert::Infallible> {
serve_web::serve_web(context!(), sw_args).await
}
Some(args::Commands::AgentHost(ah_args)) => {
agent_host::agent_host(context!(), ah_args).await
}
Some(args::Commands::Tunnel(mut tunnel_args)) => match tunnel_args.subcommand.take() {
Some(args::TunnelSubcommand::Prune) => tunnels::prune(context!()).await,
Some(args::TunnelSubcommand::Unregister) => tunnels::unregister(context!()).await,