We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 8907b3d + 3d466a2 commit 566ec6fCopy full SHA for 566ec6f
pkg/inference/scheduling/runner.go
@@ -118,6 +118,12 @@ func run(
118
r.URL.Path = trimRequestPathToOpenAIRoot(r.URL.Path)
119
r.URL.RawPath = trimRequestPathToOpenAIRoot(r.URL.RawPath)
120
}
121
+ proxy.ModifyResponse = func(resp *http.Response) error {
122
+ // CORS headers are set by the CorsMiddleware from pkg/inference/cors.go,
123
+ // so we remove them here to avoid duplication and potential misconfiguration.
124
+ resp.Header.Del("Access-Control-Allow-Origin")
125
+ return nil
126
+ }
127
proxy.Transport = transport
128
proxyLog := log.Writer()
129
proxy.ErrorLog = logpkg.New(proxyLog, "", 0)
0 commit comments