fastapi based on python 3.6
196
pull image from repository
docker pull ivandemartino/fastapi:tag
create a folder on you filesystem (ex:/home/myuser/somefolder) and, inside it, copy your fastapi application with file name run.py
create container:
execute command:
docker run -it -v "your-folder":/src/app --name choosename --publish 8000:8000 ivandemartino/fastapi:tag
for first run copy the following code to your run.py
from fastapi import FastAPI
app = FastAPI()
@app.get("/")
def read_root():
return { "Lux app": "Welcome to Lux app" }
this is a python3.6 fastapi image with the following pip requirements:
Content type
Image
Digest
Size
159.8 MB
Last updated
almost 5 years ago
docker pull ivandemartino/fastapi:python36-alpine