feat: thumbnail service CORS config

This commit is contained in:
Benedikt Kulmann
2024-05-28 08:35:13 +02:00
committed by Michael Barz
parent 73da706d52
commit 6b697d77ba
4 changed files with 27 additions and 0 deletions

View File

@@ -23,6 +23,10 @@ func Server(opts ...Option) (*http.Server, error) {
debug.Zpages(options.Config.Debug.Zpages),
debug.Health(health(options.Config)),
debug.Ready(ready(options.Config)),
debug.CorsAllowedOrigins(options.Config.HTTP.CORS.AllowedOrigins),
debug.CorsAllowedMethods(options.Config.HTTP.CORS.AllowedMethods),
debug.CorsAllowedHeaders(options.Config.HTTP.CORS.AllowedHeaders),
debug.CorsAllowCredentials(options.Config.HTTP.CORS.AllowCredentials),
), nil
}