Skip to content

Commit

Permalink
Check method as well as path
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinmcconnell committed Jul 24, 2024
1 parent 4114960 commit 9bd82c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/server/target.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ func (t *Target) SendRequest(w http.ResponseWriter, req *http.Request) {
}

func (t *Target) IsHealthCheckRequest(r *http.Request) bool {
return t.options.HealthCheckConfig.Path == r.URL.Path
return r.Method == http.MethodGet && r.URL.Path == t.options.HealthCheckConfig.Path
}

func (t *Target) Rewrite(req *httputil.ProxyRequest) {
Expand Down

0 comments on commit 9bd82c9

Please sign in to comment.