mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-03 00:40:25 +02:00
controlplane: remove gorilla handlers dependency (#3813)
This commit is contained in:
parent
b375dc4896
commit
27c94396a8
4 changed files with 21 additions and 9 deletions
|
@ -7,12 +7,12 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/CAFxX/httpcompression"
|
||||
gorillahandlers "github.com/gorilla/handlers"
|
||||
"github.com/gorilla/mux"
|
||||
|
||||
"github.com/pomerium/pomerium/config"
|
||||
"github.com/pomerium/pomerium/internal/handlers"
|
||||
"github.com/pomerium/pomerium/internal/log"
|
||||
"github.com/pomerium/pomerium/internal/middleware"
|
||||
"github.com/pomerium/pomerium/internal/telemetry"
|
||||
"github.com/pomerium/pomerium/internal/telemetry/requestid"
|
||||
)
|
||||
|
@ -37,7 +37,7 @@ func (srv *Server) addHTTPMiddleware(root *mux.Router, cfg *config.Config) {
|
|||
Str("path", r.URL.String()).
|
||||
Msg("http-request")
|
||||
}))
|
||||
root.Use(gorillahandlers.RecoveryHandler())
|
||||
root.Use(middleware.Recovery)
|
||||
root.Use(log.RemoteAddrHandler("ip"))
|
||||
root.Use(log.UserAgentHandler("user_agent"))
|
||||
root.Use(log.RefererHandler("referer"))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue