Build-Test

This commit is contained in:
2025-09-06 17:14:25 +02:00
parent bb33278399
commit 0e7087bd08
4 changed files with 191 additions and 27 deletions

View File

@@ -480,14 +480,14 @@ func (s *Server) routes() http.Handler {
mux.HandleFunc("/status", s.handleStatus)
// Static UI
sub, _ := fs.Sub(embedded, "web")
sub, _ := fs.Sub(embedded, "/web")
mux.Handle("/", http.FileServer(http.FS(sub)))
return mux
}
func main() {
port := getenv("PORT", "8080")
port := getenv("PORT", ":8080")
maxPerRoom := getenvInt("MAX_PER_ROOM", 200)
secret := os.Getenv("CLIPBOARD_TOKEN")
persist := os.Getenv("CLIPBOARD_DATA")
@@ -498,7 +498,7 @@ func main() {
}
srv := &http.Server{
Addr: ":" + port,
Addr: port,
Handler: s.routes(),
ReadHeaderTimeout: 10 * time.Second,
}