Skip to content

Commit

Permalink
docs: Add running instructions. #1796
Browse files Browse the repository at this point in the history
  • Loading branch information
mturoci committed Feb 24, 2023
1 parent 67c212a commit 3e970ba
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions py/h2o_wavelite/examples/hello_fastapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ async def serve(q: Q):
await q.page.save()


# Run: uvicorn hello_fastapi:app.
# FastAPI boilerplate.
app = FastAPI()

Expand Down
1 change: 1 addition & 0 deletions py/h2o_wavelite/examples/hello_fastapi_custom_index.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ async def serve(q: Q):
await q.page.save()


# Run: uvicorn hello_fastapi_custom_index:app.
# FastAPI boilerplate.
app = FastAPI()

Expand Down
1 change: 1 addition & 0 deletions py/h2o_wavelite/examples/hello_starlette.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,6 @@ async def socket(ws):
Mount("/", app=StaticFiles(directory=web_directory, html=True), name="/")
])

# Run: python hello_starlette.py
if __name__ == '__main__':
uvicorn.run(startlette_app, host='0.0.0.0', port=5000)
1 change: 1 addition & 0 deletions py/h2o_wavelite/examples/hello_starlette_custom_index.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,6 @@ async def socket(ws):
Route('/', lambda _r: FileResponse(os.path.join(curr_dir, 'index.html'))),
])

# Run: python hello_starlette.py
if __name__ == '__main__':
uvicorn.run(startlette_app, host='0.0.0.0', port=5000)

0 comments on commit 3e970ba

Please sign in to comment.