feat(webui): bootstrap session handling and login process

This commit is contained in:
Julien Dessaux 2025-01-06 00:41:32 +01:00
parent 63e2b1b09d
commit 6e069484cb
Signed by: adyxax
GPG key ID: F92E51B86E07177E
18 changed files with 447 additions and 1 deletions

16
pkg/webui/index.go Normal file
View file

@ -0,0 +1,16 @@
package webui
import (
"html/template"
"net/http"
)
var indexTemplates = template.Must(template.ParseFS(htmlFS, "html/base.html", "html/index.html"))
func handleIndexGET() http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
w.Header().Set("Cache-Control", "no-store, no-cache")
render(w, indexTemplates, http.StatusOK, nil)
})
}