read map from config file
This commit is contained in:
@ -1,10 +1,8 @@
|
||||
import asyncio
|
||||
import json
|
||||
from typing import Dict
|
||||
|
||||
from redis import asyncio as aioredis
|
||||
import uvicorn
|
||||
from fastapi import FastAPI, BackgroundTasks, UploadFile
|
||||
from fastapi import FastAPI, BackgroundTasks
|
||||
|
||||
app = FastAPI()
|
||||
|
||||
@ -27,7 +25,7 @@ async def event_rcv(data: dict, background_tasks: BackgroundTasks):
|
||||
|
||||
|
||||
def run_app():
|
||||
uvicorn.run("main:app", host="0.0.0.0", port=8000)
|
||||
uvicorn.run(app=app, host="0.0.0.0", port=8000)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
Reference in New Issue
Block a user