diff --git a/src/backend/chart-server/chart-api/src/main/kotlin/com/lalala/chart/config/WebConfiguration.kt b/src/backend/chart-server/chart-api/src/main/kotlin/com/lalala/chart/config/WebConfiguration.kt new file mode 100644 index 00000000..ecf790d4 --- /dev/null +++ b/src/backend/chart-server/chart-api/src/main/kotlin/com/lalala/chart/config/WebConfiguration.kt @@ -0,0 +1,17 @@ +package com.lalala.chart.config + +import org.springframework.context.annotation.Configuration +import org.springframework.web.reactive.config.CorsRegistry +import org.springframework.web.reactive.config.WebFluxConfigurer + +@Configuration +class WebConfiguration : WebFluxConfigurer { + override fun addCorsMappings(registry: CorsRegistry) { + registry.addMapping("/**") + .allowedOrigins("*") + .allowedMethods("*") + .allowedHeaders("*") + .allowCredentials(false) + .maxAge(60000) + } +}