/fastapi

Sample implementation of fastapi + uvicorn web framework and benchmarking

Primary LanguageDockerfile

Local Docker Setup

  1. Uvicorn
docker container stop api-demo
docker container rm api-demo
docker rmi api-demo:v1
docker build -t api-demo:v1 -f server.Dockerfile .
docker run -d -p 8000:5000 --name api-demo api-demo:v1
  1. Gunicorn
docker container stop fastapi_gunicorn
docker container rm api-demo
docker rmi api-demo:v1.2
docker build -t api-demo:v1.2 -f gunicorn.Dockerfile .
docker run -d -p 8000:5000 --name fastapi_gunicorn api-demo:v1.2