Cleanup: MB 2.0 Gap Analysis előtti állapot (adatok kizárva)
This commit is contained in:
@@ -6,10 +6,12 @@ from starlette.middleware.sessions import SessionMiddleware # ÚJ
|
||||
from app.api.v1.api import api_router
|
||||
from app.core.config import settings
|
||||
|
||||
# Statikus mappák létrehozása induláskor
|
||||
os.makedirs("static/previews", exist_ok=True)
|
||||
|
||||
app = FastAPI(
|
||||
title="Service Finder API",
|
||||
description="Traffic Ecosystem, Asset Vault & AI Evidence Processing",
|
||||
version="2.0.0",
|
||||
openapi_url="/api/v1/openapi.json",
|
||||
docs_url="/docs"
|
||||
@@ -21,6 +23,7 @@ app.add_middleware(
|
||||
secret_key=settings.SECRET_KEY
|
||||
)
|
||||
|
||||
# --- CORS BEÁLLÍTÁSOK ---
|
||||
app.add_middleware(
|
||||
CORSMiddleware,
|
||||
allow_origins=[
|
||||
@@ -34,13 +37,30 @@ app.add_middleware(
|
||||
allow_headers=["*"],
|
||||
)
|
||||
|
||||
# Statikus fájlok kiszolgálása (képek, letöltések)
|
||||
app.mount("/static", StaticFiles(directory="static"), name="static")
|
||||
|
||||
# A V1-es API router bekötése a /api/v1 prefix alá
|
||||
app.include_router(api_router, prefix="/api/v1")
|
||||
|
||||
@app.get("/")
|
||||
# --- ALAPVETŐ VÉGPONTOK ---
|
||||
@app.get("/", tags=["System"])
|
||||
async def root():
|
||||
return {
|
||||
"status": "online",
|
||||
"message": "Service Finder Master System v2.0",
|
||||
"features": ["Google Auth Enabled", "Asset Vault", "Org Onboarding"]
|
||||
}
|
||||
"features": [
|
||||
"Google Auth Enabled",
|
||||
"Asset Vault",
|
||||
"Org Onboarding",
|
||||
"AI Evidence OCR (Robot 3)",
|
||||
"Fleet Expenses (TCO)"
|
||||
]
|
||||
}
|
||||
|
||||
@app.get("/health", tags=["System"])
|
||||
async def health_check():
|
||||
"""
|
||||
Monitoring és Load Balancer egészségügyi ellenőrző végpont.
|
||||
"""
|
||||
return {"status": "ok", "message": "Service Finder API is running flawlessly."}
|
||||
Reference in New Issue
Block a user