Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ require (
github.com/coredhcp/coredhcp v0.0.0-20231020075302-1cd0fca8759a
github.com/dustin/go-humanize v1.0.1
github.com/fatih/color v1.19.0
github.com/go-chi/chi/v5 v5.2.5
github.com/go-chi/chi/v5 v5.3.0
github.com/go-logr/logr v1.4.3
github.com/google/uuid v1.6.0
github.com/insomniacslk/dhcp v0.0.0-20231206064809-8c70d406f6d2
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ github.com/fxamacker/cbor/v2 v2.9.0 h1:NpKPmjDBgUfBms6tr6JZkTHtfFGcMKsw3eGcmD/sa
github.com/fxamacker/cbor/v2 v2.9.0/go.mod h1:vM4b+DJCtHn+zz7h3FFp/hDAI9WNWCsZj23V5ytsSxQ=
github.com/githedgehog/ygot v0.32.0-hh1 h1:x3QetdURBsGNGPd5/ywQXDxu5Ga7xKaT1dLyoGWZqOU=
github.com/githedgehog/ygot v0.32.0-hh1/go.mod h1:sMTAECRlEmETQ36XaAbWav5AFrR6EZlNNcHyZ7KHBDE=
github.com/go-chi/chi/v5 v5.2.5 h1:Eg4myHZBjyvJmAFjFvWgrqDTXFyOzjj7YIm3L3mu6Ug=
github.com/go-chi/chi/v5 v5.2.5/go.mod h1:X7Gx4mteadT3eDOMTsXzmI4/rwUpOwBHLpAfupzFJP0=
github.com/go-chi/chi/v5 v5.3.0 h1:halUjDxhshgXHMrao5bB8eNBXo/rnzwr8m5m36glehM=
github.com/go-chi/chi/v5 v5.3.0/go.mod h1:R+tYY2hNuVUUjxoPtqUdgBqevM9s9njzkTLutVsOCto=
github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI=
github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
Expand Down
2 changes: 1 addition & 1 deletion pkg/boot/server/middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func RequestLogger(next http.Handler) http.Handler {
"rid", rid,
"method", r.Method,
"url", fmt.Sprintf("%s://%s%s", scheme, r.Host, r.RequestURI),
"from", r.RemoteAddr,
"from", middleware.GetClientIP(r.Context()),
"status", ww.Status(),
"size", ww.BytesWritten(),
"took", time.Since(start).Milliseconds(),
Expand Down
2 changes: 1 addition & 1 deletion pkg/boot/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,9 @@ func Run(ctx context.Context) error {
r := chi.NewRouter()

r.Use(middleware.RequestID)
r.Use(middleware.ClientIPFromRemoteAddr)
r.Use(RequestLogger)
r.Use(middleware.Recoverer)
r.Use(middleware.RealIP)
r.Use(ResponseRequestID)
r.Use(middleware.Heartbeat("/healthz"))
r.Use(middleware.Timeout(300 * time.Second))
Expand Down
70 changes: 68 additions & 2 deletions vendor/github.com/go-chi/chi/v5/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/github.com/go-chi/chi/v5/chi.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading