diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index d7f1e24..df0845d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -5,11 +5,13 @@ mod cert; mod cert_store; mod consul; mod http; +mod https; mod proxy_config; +mod reverse_proxy; use log::*; -#[tokio::main(flavor = "multi_thread")] +#[tokio::main(flavor = "multi_thread", worker_threads = 10)] async fn main() { if std::env::var("RUST_LOG").is_err() { std::env::set_var("RUST_LOG", "tricot=debug") @@ -28,6 +30,10 @@ async fn main() { ); tokio::spawn(http::serve_http(consul.clone())); + tokio::spawn(https::serve_https( + cert_store.clone(), + rx_proxy_config.clone(), + )); while rx_proxy_config.changed().await.is_ok() { info!("Proxy config: {:#?}", *rx_proxy_config.borrow()); |