fix: update CORS allowed origins for better security
This commit is contained in:
parent
5fcb574aca
commit
ed6c656963
12
app/main.py
12
app/main.py
|
|
@ -38,12 +38,12 @@ def create_app() -> FastAPI:
|
||||||
application.add_middleware(
|
application.add_middleware(
|
||||||
CORSMiddleware,
|
CORSMiddleware,
|
||||||
allow_origins=[
|
allow_origins=[
|
||||||
# "https://kitchen-crm.k1nq.tech",
|
"https://kitchen-crm.k1nq.tech",
|
||||||
# "http://192.168.31.51",
|
"http://192.168.31.51",
|
||||||
# "http://localhost:8000",
|
"http://localhost:8000",
|
||||||
# "http://0.0.0.0:8000",
|
"http://0.0.0.0:8000",
|
||||||
# "http://127.0.0.1:8000",
|
"http://127.0.0.1:8000",
|
||||||
"*", # ! TODO: Убрать
|
# "*",
|
||||||
],
|
],
|
||||||
allow_credentials=True,
|
allow_credentials=True,
|
||||||
allow_methods=["*"], # Разрешить все HTTP-методы
|
allow_methods=["*"], # Разрешить все HTTP-методы
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue