feat: implements a better kubernetes deployment setup

This commit is contained in:
2025-11-08 19:59:07 -03:00
parent 114cc99a52
commit c615a71277
12 changed files with 184 additions and 42 deletions

View File

@@ -1,4 +1,3 @@
from storage_service.config.config_allowed_origins import get_allowed_origins
from storage_service.controller import health_router, storage_router
from storage_service.utils.exception_handler import (
http_exception_handler,
@@ -7,7 +6,6 @@ from storage_service.utils.exception_handler import (
from fastapi import FastAPI, HTTPException
from fastapi.exceptions import RequestValidationError
from fastapi.middleware.cors import CORSMiddleware
app = FastAPI()
@@ -15,14 +13,5 @@ app = FastAPI()
app.add_exception_handler(HTTPException, http_exception_handler)
app.add_exception_handler(RequestValidationError, validation_exception_handler)
app.add_middleware(
CORSMiddleware,
allow_origins=get_allowed_origins(),
allow_credentials=True,
allow_methods=["*"],
allow_headers=["*"],
)
app.include_router(storage_router)
app.include_router(health_router)