about summary refs log tree commit diff stats
path: root/internal/server/server.go
diff options
context:
space:
mode:
authorAlan Pearce2024-05-09 18:24:58 +0200
committerAlan Pearce2024-05-09 19:27:57 +0200
commit99d5507b223baa6c780707d32c7bbbb8611034f0 (patch)
treeb982d873e7bd58ef9ad9544074d4475b5de27dfb /internal/server/server.go
parent14c1ddaf7c5468c5966b0c1585f19a5ff39c206d (diff)
downloadsearchix-99d5507b223baa6c780707d32c7bbbb8611034f0.tar.lz
searchix-99d5507b223baa6c780707d32c7bbbb8611034f0.tar.zst
searchix-99d5507b223baa6c780707d32c7bbbb8611034f0.zip
feat: allow configuration of log level
Diffstat (limited to 'internal/server/server.go')
-rw-r--r--internal/server/server.go17
1 files changed, 9 insertions, 8 deletions
diff --git a/internal/server/server.go b/internal/server/server.go
index f15d011..1611a7a 100644
--- a/internal/server/server.go
+++ b/internal/server/server.go
@@ -36,14 +36,15 @@ var (
 )
 
 type Config struct {
-	Production    bool    `conf:"default:false"`
-	InDevServer   bool    `conf:"default:false"`
-	LiveReload    bool    `conf:"default:false,flag:live"`
-	Root          string  `conf:"default:website"`
-	ListenAddress string  `conf:"default:localhost"`
-	Port          string  `conf:"default:3000,short:p"`
-	BaseURL       cfg.URL `conf:"default:http://localhost:3000,short:b"`
-	ConfigFile    string  `conf:"short:c"`
+	Production    bool       `conf:"default:false"`
+	InDevServer   bool       `conf:"default:false"`
+	LiveReload    bool       `conf:"default:false,flag:live"`
+	Root          string     `conf:"default:website"`
+	ListenAddress string     `conf:"default:localhost"`
+	Port          string     `conf:"default:3000,short:p"`
+	BaseURL       cfg.URL    `conf:"default:http://localhost:3000,short:b"`
+	ConfigFile    string     `conf:"short:c"`
+	LogLevel      slog.Level `conf:"default:INFO"`
 }
 
 type HTTPError struct {