Skip to content

Latest commit

 

History

History
44 lines (31 loc) · 786 Bytes

File metadata and controls

44 lines (31 loc) · 786 Bytes

easy_fastapi

user@box:~/easy_fastapi $ uvicorn simple_main:app --reload --host 0.0.0.0 --port 8001

Venv (initial setup)

user@DevTerm1:~/easy_fastapi $ python3 -m venv .venv

user@DevTerm1:~/easy_fastapi $ . ./.venv/bin/activate
(.venv) user@DevTerm1:~/easy_fastapi $

venv (activate)

(.venv) user@DevTerm1:~/easy_fastapi $ which pip
/home/user/easy_fastapi/.venv/bin/pip

dependencies

pip install loguru 
pip install pydantic  
pip install "uvicorn[standard]"
pip install fastapi fastapi-utils
 uvicorn --reload main:app  --host 0.0.0.0 --port

Simple example of using fastapi Most of this was taken from fastapi

pre_reqs

pip install uvicorn fastapi

Running

user@box:~/easy_fastapi$ python3 ./main.py