Skip to content

Commit 0c25197

Browse files
committed
fix: CORS Origins 프론트와 로컬호스트만 명시
1 parent 5059642 commit 0c25197

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ func createServer(cfg *config.Config) (*gin.Engine, *ent.Client, error) {
4545

4646
r := gin.Default()
4747
corsConfig := cors.Config{
48-
AllowOrigins: []string{"*"},
48+
AllowOrigins: []string{"https://techbloghub.net", "https://localhost:3000", "http://localhost:3000"},
4949
AllowMethods: []string{"GET", "POST", "OPTIONS", "DELETE", "PUT", "PATCH"},
5050
AllowHeaders: []string{"Origin", "Content-Type", "Authorization"},
5151
ExposeHeaders: []string{"Content-Length"},

0 commit comments

Comments
 (0)