mirror of
https://github.com/amir20/dozzle.git
synced 2025-12-24 06:28:42 +01:00
feat: uses brotli on the fly for static files and gzip for streaming (#3825)
This commit is contained in:
@@ -140,7 +140,7 @@ func createRouter(h *handler) *chi.Mux {
|
||||
r.Get("/healthcheck", h.healthcheck)
|
||||
|
||||
defaultHandler := http.StripPrefix(strings.Replace(base+"/", "//", "/", 1), http.HandlerFunc(h.index))
|
||||
r.Get("/*", func(w http.ResponseWriter, req *http.Request) {
|
||||
r.With(Brotli).Get("/*", func(w http.ResponseWriter, req *http.Request) {
|
||||
defaultHandler.ServeHTTP(w, req)
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user