From 44a60cff1127da5b894acb4dc3e176f1f9770dad Mon Sep 17 00:00:00 2001 From: yggverse Date: Thu, 5 Mar 2026 22:54:11 +0200 Subject: [PATCH] use ipv6 by default, remove extra config options --- crates/httpd/config.toml | 4 +--- crates/httpd/src/config.rs | 2 -- crates/httpd/src/global.rs | 1 - crates/httpd/src/main.rs | 2 -- crates/httpd/src/meta.rs | 1 - 5 files changed, 1 insertion(+), 9 deletions(-) diff --git a/crates/httpd/config.toml b/crates/httpd/config.toml index fda5933..570c9b5 100644 --- a/crates/httpd/config.toml +++ b/crates/httpd/config.toml @@ -1,9 +1,7 @@ title = "HLState" -format_time = "%d/%m/%Y %H:%M" - # Bind server on given host -host = "127.0.0.1" +host = "[::1]" # Bind server on given port port = 8027 diff --git a/crates/httpd/src/config.rs b/crates/httpd/src/config.rs index 57c4471..83010b3 100644 --- a/crates/httpd/src/config.rs +++ b/crates/httpd/src/config.rs @@ -8,8 +8,6 @@ use std::{ #[serde(crate = "rocket::serde")] pub struct Config { pub debug: bool, - pub description: Option, - pub format_time: String, pub host: IpAddr, pub masters: HashSet, pub port: u16, diff --git a/crates/httpd/src/global.rs b/crates/httpd/src/global.rs index 56bb4d0..67cc4e4 100644 --- a/crates/httpd/src/global.rs +++ b/crates/httpd/src/global.rs @@ -4,6 +4,5 @@ use std::collections::HashSet; #[derive(Clone, Debug, Serialize)] #[serde(crate = "rocket::serde")] pub struct Global { - pub format_time: String, pub masters: HashSet, } diff --git a/crates/httpd/src/main.rs b/crates/httpd/src/main.rs index db31415..8ba8a1e 100644 --- a/crates/httpd/src/main.rs +++ b/crates/httpd/src/main.rs @@ -77,11 +77,9 @@ fn rocket() -> _ { } }) .manage(Global { - format_time: config.format_time, masters: config.masters, }) .manage(Meta { - description: config.description, title: config.title, version: env!("CARGO_PKG_VERSION").into(), }) diff --git a/crates/httpd/src/meta.rs b/crates/httpd/src/meta.rs index c8512d0..10745ce 100644 --- a/crates/httpd/src/meta.rs +++ b/crates/httpd/src/meta.rs @@ -3,7 +3,6 @@ use rocket::serde::Serialize; #[derive(Clone, Debug, Serialize)] #[serde(crate = "rocket::serde")] pub struct Meta { - pub description: Option, pub title: String, pub version: String, }