Get Addr, ReadTimeout and WriteTimeout from the config

This commit is contained in:
henk
2026-05-15 17:11:16 +02:00
parent e38d34bf5f
commit ec9dfa17d0

View File

@@ -30,7 +30,10 @@ func (s *Server) setup() error {
mux.HandleFunc("/health", s.handleHealth)
s.httpServer = &http.Server{
Handler: mux,
Addr: s.cfg.Server.BindAddress,
Handler: mux,
ReadTimeout: s.cfg.Server.ReadTimeout,
WriteTimeout: s.cfg.Server.WriteTimeout,
}
return nil
}