Skip to content

Commit 98a1e89

Browse files
authored
fix: http -> https CORS 문제 해결 (#147)
1 parent e517b99 commit 98a1e89

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/main/java/com/somemore/global/configure/SwaggerConfig.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
package com.somemore.global.configure;
22

3+
import io.swagger.v3.oas.annotations.OpenAPIDefinition;
4+
import io.swagger.v3.oas.annotations.servers.Server;
35
import io.swagger.v3.oas.models.Components;
46
import io.swagger.v3.oas.models.OpenAPI;
57
import io.swagger.v3.oas.models.info.Info;
@@ -8,6 +10,11 @@
810
import org.springframework.context.annotation.Bean;
911
import org.springframework.context.annotation.Configuration;
1012

13+
@OpenAPIDefinition(
14+
servers = {
15+
@Server(url = "https://api.somemore.site", description = "개발 서버"),
16+
@Server(url = "http://localhost:8080", description = "로컬 서버")
17+
})
1118
@Configuration
1219
public class SwaggerConfig {
1320

0 commit comments

Comments
 (0)