From 52851787329c48c1e70f98a3610ad52fe1fa4aa4 Mon Sep 17 00:00:00 2001 From: FxQnLr Date: Mon, 8 Apr 2024 15:14:21 +0200 Subject: Closes #25. Apikey not required anymore --- src/config.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/config.rs') diff --git a/src/config.rs b/src/config.rs index 9605361..9636af4 100644 --- a/src/config.rs +++ b/src/config.rs @@ -1,14 +1,22 @@ use config::File; use serde::Deserialize; +use crate::auth; + #[derive(Debug, Clone, Deserialize)] pub struct Config { pub database_url: String, - pub apikey: String, pub serveraddr: String, pub pingtimeout: i64, pub pingthreshold: i64, pub timeoffset: i8, + pub auth: Auth, +} + +#[derive(Debug, Clone, Deserialize)] +pub struct Auth { + pub method: auth::Methods, + pub secret: String, } impl Config { -- cgit v1.2.3