1use std::net::SocketAddr;
4use typed_builder::TypedBuilder;
5
6#[derive(Clone, Debug, TypedBuilder)]
8pub struct Config {
9 #[builder(default = "127.0.0.1:3000".parse().unwrap())]
11 pub sock: SocketAddr,
12
13 #[builder(default = None)]
15 pub log: Option<String>,
16
17 #[builder(default = "/".into())]
19 pub home_path: String,
20
21 #[builder(default = "/slash-command".into())]
23 pub slash_command_path: String,
24
25 #[builder(default = "/oauth/v2/redirect".into())]
27 pub oauth_path: String,
28
29 #[builder(default = StaticPathConfig::builder().build())]
31 pub static_path: StaticPathConfig,
32}
33
34#[derive(Clone, Debug, TypedBuilder)]
36pub struct StaticPathConfig {
37 #[builder(default = "/remote".to_string())]
39 pub http: String,
40
41 #[builder(default = "./assets/remote".to_string())]
43 pub local: String,
44}