feat(web): add --disable-registration flag to disable user registration (#1881)

This commit is contained in:
Mg Pig
2026-02-13 16:03:11 +08:00
committed by GitHub
parent 011770a601
commit 3512a80597
4 changed files with 37 additions and 4 deletions
+8
View File
@@ -109,6 +109,13 @@ struct Cli {
help = t!("cli.api_host").to_string()
)]
api_host: Option<url::Url>,
#[arg(
long,
default_value = "false",
help = t!("cli.disable_registration").to_string(),
)]
disable_registration: bool,
}
impl LoggingConfigLoader for &Cli {
@@ -212,6 +219,7 @@ async fn main() {
mgr.clone(),
db,
web_router_restful,
cli.disable_registration,
)
.await
.unwrap()