FROM python:3.8.12-slim-bullseye ENV ENVIRONMENT development VOLUME /app WORKDIR /app RUN apt-get update &&\ apt-get install build-essential -y &&\ rm -rf /var/lib/apt/lists/* RUN python3 -m pip install --no-cache-dir --upgrade pip &&\ python3 -m pip install --no-cache-dir en-core-web-sm@https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-3.3.0/en_core_web_sm-3.3.0-py3-none-any.whl COPY requirements.txt ./ RUN python3 -m pip install --no-cache-dir -r requirements.txt EXPOSE 5000 VOLUME /dependencies CMD ["/bin/bash", "-c", "python3 -m pip install -e /dependencies/sus && python3 -m uvicorn --reload --host 0.0.0.0 --port 5000 main:app"]