Skip to main content

trojan_agent/
lib.rs

1//! Trojan panel agent — connects to a centralized management panel via
2//! WebSocket, receives full configuration, boots the appropriate service,
3//! and reports heartbeat + traffic back.
4//!
5//! # Usage
6//!
7//! ```bash
8//! trojan agent -c agent.toml
9//! ```
10//!
11//! The agent TOML only needs `panel_url` and `token`. Everything else
12//! (TLS certs, listen addresses, auth, chains) comes from the panel.
13
14pub mod cache;
15pub mod cli;
16pub mod client;
17pub mod collector;
18pub mod config;
19pub mod error;
20pub mod protocol;
21pub mod reporter;
22pub mod runner;
23
24pub use cli::AgentArgs;
25pub use error::AgentError;