From fffe0724a27a5c1ac088c518306379fea0389708 Mon Sep 17 00:00:00 2001 From: minsuhan1 Date: Thu, 25 Sep 2025 16:57:18 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20=EB=B0=B1=EC=97=94?= =?UTF-8?q?=EB=93=9C=20CORS=20=ED=97=88=EC=9A=A9=EB=8F=84=EB=A9=94?= =?UTF-8?q?=EC=9D=B8=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/app/main.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/backend/app/main.py b/backend/app/main.py index a0222f5..535594e 100644 --- a/backend/app/main.py +++ b/backend/app/main.py @@ -140,10 +140,18 @@ class DepartTimeRequest(BaseModel): app = FastAPI(title="Simple Test API") -# CORS 설정 - 개발 환경용 +# CORS 설정 - 개발 및 프로덕션 환경 app.add_middleware( CORSMiddleware, - allow_origins=["http://localhost:3000", "http://127.0.0.1:3000", "http://localhost:3001", "http://127.0.0.1:3001"], + allow_origins=[ + "http://localhost:3000", + "http://127.0.0.1:3000", + "http://localhost:3001", + "http://127.0.0.1:3001", + "https://daejeon-evolution.com", + "https://www.daejeon-evolution.com", + "https://api.daejeon-evolution.com" + ], allow_credentials=True, allow_methods=["GET", "POST", "PUT", "DELETE", "OPTIONS"], allow_headers=["Content-Type", "Authorization", "X-Requested-With"],