17 lines
365 B
Python
17 lines
365 B
Python
import asyncio
|
|
|
|
from fastapi import FastAPI
|
|
from starlette.middleware.trustedhost import TrustedHostMiddleware
|
|
|
|
from models.sqlite import Sqlite
|
|
|
|
loop = asyncio.get_event_loop()
|
|
app = FastAPI()
|
|
app.add_middleware(
|
|
TrustedHostMiddleware, allowed_hosts=["127.0.0.1"]
|
|
)
|
|
sqlite = Sqlite()
|
|
need_auth_routes = []
|
|
need_auth_uid_only_routes = []
|
|
need_admin_routes = []
|