File tree Expand file tree Collapse file tree 3 files changed +14
-8
lines changed Expand file tree Collapse file tree 3 files changed +14
-8
lines changed Original file line number Diff line number Diff line change 1- import azure .functions as func
1+ # import azure.functions as func
22from fastapi import FastAPI
33from function .api .v1 .api_v1 import api_v1_router
44from function .core .config import settings
@@ -28,11 +28,11 @@ async def shutdown_event():
2828 pass
2929
3030
31- app = func .AsgiFunctionApp (
32- app = fastapi_app ,
33- http_auth_level = func .AuthLevel .ANONYMOUS ,
34- )
31+ # app = func.AsgiFunctionApp(
32+ # app=fastapi_app,
33+ # http_auth_level=func.AuthLevel.ANONYMOUS,
34+ # )
3535
3636
37- async def main (req : func .HttpRequest , context : func .Context ) -> func .HttpResponse :
38- return await func .AsgiMiddleware (fastapi_app ).handle_async (req , context )
37+ # async def main(req: func.HttpRequest, context: func.Context) -> func.HttpResponse:
38+ # return await func.AsgiMiddleware(fastapi_app).handle_async(req, context)
Original file line number Diff line number Diff line change 1+ import azure .functions as func
2+ from function .main import fastapi_app
3+
4+
5+ async def main (req : func .HttpRequest , context : func .Context ) -> func .HttpResponse :
6+ return await func .AsgiMiddleware (fastapi_app ).handle_async (req , context )
Original file line number Diff line number Diff line change 11{
2- "scriptFile" : " function_app .py" ,
2+ "scriptFile" : " __init__ .py" ,
33 "bindings" : [
44 {
55 "authLevel" : " anonymous" ,
You can’t perform that action at this time.
0 commit comments