1 / Dockerfile
rkihacker's picture
Update Dockerfile
bc849ab verified
raw
history blame
358 Bytes
# Use Python 3.9 (because why not?)
FROM python:3.9-slim
# Install dependencies (because we need socket magic)
RUN pip install fastapi uvicorn
# Copy the code
COPY main.py
# Expose port 8000 (because FastAPI defaults to it)
EXPOSE 8000
# Run the API (because we need to start the chaos)
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]