Skip to main content
Sign in
Snippets Groups Projects
Select Git revision
  • d477b075037b1c1703c0d2deeb09860b3a3b43b6
  • main default protected
  • develop
  • 2.3.1
  • 2.3.0
  • 2.2.3
  • 2.2.2
7 results

README.md

Blame
  • Dockerfile 1.08 KiB
    FROM onerahmet/ffmpeg:n7.1 AS ffmpeg
    
    FROM swaggerapi/swagger-ui:v5.9.1 AS swagger-ui
    
    FROM python:3.10-bookworm
    
    RUN export DEBIAN_FRONTEND=noninteractive \
        && apt-get -qq update \
        && apt-get -qq install --no-install-recommends \
        libsndfile1 \
        && rm -rf /var/lib/apt/lists/*
    
    ENV POETRY_VENV=/app/.venv
    
    RUN python3 -m venv $POETRY_VENV \
        && $POETRY_VENV/bin/pip install -U pip setuptools \
        && $POETRY_VENV/bin/pip install poetry==1.6.1
    
    ENV PATH="${PATH}:${POETRY_VENV}/bin"
    
    WORKDIR /app
    
    COPY . /app
    COPY --from=ffmpeg /usr/local/bin/ffmpeg /usr/local/bin/ffmpeg
    COPY --from=swagger-ui /usr/share/nginx/html/swagger-ui.css swagger-ui-assets/swagger-ui.css
    COPY --from=swagger-ui /usr/share/nginx/html/swagger-ui-bundle.js swagger-ui-assets/swagger-ui-bundle.js
    
    RUN poetry config virtualenvs.in-project true
    RUN poetry install
    
    RUN $POETRY_VENV/bin/pip install pandas transformers nltk pyannote.audio
    RUN git clone --depth 1 https://github.com/m-bain/whisperX.git \
        && cd whisperX \
        && $POETRY_VENV/bin/pip install -e .
    
    EXPOSE 9000
    
    ENTRYPOINT ["whisper-asr-webservice"]