mirror of
https://github.com/ollama/ollama.git
synced 2025-07-28 14:13:10 +02:00
Merge pull request #10276 from ollama/drifkin/cors-headers
server: add `OpenAI-Beta` header to CORS safelist
This commit is contained in:
@@ -1152,17 +1152,18 @@ func (s *Server) GenerateRoutes(rc *ollama.Registry) (http.Handler, error) {
|
|||||||
"X-Requested-With",
|
"X-Requested-With",
|
||||||
|
|
||||||
// OpenAI compatibility headers
|
// OpenAI compatibility headers
|
||||||
"x-stainless-lang",
|
"OpenAI-Beta",
|
||||||
"x-stainless-package-version",
|
|
||||||
"x-stainless-os",
|
|
||||||
"x-stainless-arch",
|
"x-stainless-arch",
|
||||||
|
"x-stainless-async",
|
||||||
|
"x-stainless-custom-poll-interval",
|
||||||
|
"x-stainless-helper-method",
|
||||||
|
"x-stainless-lang",
|
||||||
|
"x-stainless-os",
|
||||||
|
"x-stainless-package-version",
|
||||||
|
"x-stainless-poll-helper",
|
||||||
"x-stainless-retry-count",
|
"x-stainless-retry-count",
|
||||||
"x-stainless-runtime",
|
"x-stainless-runtime",
|
||||||
"x-stainless-runtime-version",
|
"x-stainless-runtime-version",
|
||||||
"x-stainless-async",
|
|
||||||
"x-stainless-helper-method",
|
|
||||||
"x-stainless-poll-helper",
|
|
||||||
"x-stainless-custom-poll-interval",
|
|
||||||
"x-stainless-timeout",
|
"x-stainless-timeout",
|
||||||
}
|
}
|
||||||
corsConfig.AllowOrigins = envconfig.AllowedOrigins()
|
corsConfig.AllowOrigins = envconfig.AllowedOrigins()
|
||||||
|
Reference in New Issue
Block a user