mirror of
https://github.com/Redume/Kekkai-web.git
synced 2025-01-10 00:33:46 +03:00
chore: deleted fastapi backend
This commit is contained in:
parent
0daff1dd1d
commit
7795d7de04
3 changed files with 0 additions and 30 deletions
18
main.py
18
main.py
|
@ -1,18 +0,0 @@
|
||||||
import uvicorn
|
|
||||||
from fastapi.staticfiles import StaticFiles
|
|
||||||
from starlette.responses import FileResponse
|
|
||||||
from fastapi import FastAPI
|
|
||||||
|
|
||||||
from src.routes import index
|
|
||||||
|
|
||||||
app = FastAPI()
|
|
||||||
app.include_router(index.router)
|
|
||||||
app.mount('/static/', StaticFiles(directory='./src/web/static/'))
|
|
||||||
|
|
||||||
|
|
||||||
@app.exception_handler(404)
|
|
||||||
async def not_found(req, __):
|
|
||||||
return FileResponse('./src/web/errors/404.html')
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
|
||||||
uvicorn.run(app, host='0.0.0.0', port=9000)
|
|
|
@ -1,3 +0,0 @@
|
||||||
fastapi~=0.115.2
|
|
||||||
starlette~=0.40.0
|
|
||||||
uvicorn~=0.31.1
|
|
|
@ -1,9 +0,0 @@
|
||||||
from fastapi import APIRouter
|
|
||||||
from fastapi.responses import FileResponse
|
|
||||||
|
|
||||||
router = APIRouter()
|
|
||||||
|
|
||||||
|
|
||||||
@router.get('/')
|
|
||||||
async def main():
|
|
||||||
return FileResponse('./src/web/page/index.html')
|
|
Loading…
Add table
Reference in a new issue