feat: apply local modifications to WhisperLive-Server
This commit is contained in:
+11
-9
@@ -20,22 +20,24 @@ WORKDIR /app
|
||||
|
||||
# install the requirements for running the whisper-live server
|
||||
COPY requirements/server.txt /app/
|
||||
RUN pip install -r server.txt && rm server.txt
|
||||
RUN pip install --no-cache-dir "setuptools<70.0.0" wheel
|
||||
RUN pip install -r server.txt
|
||||
RUN pip install --no-build-isolation openai-whisper==20240930
|
||||
RUN rm server.txt
|
||||
|
||||
# make the paths of the nvidia libs installed as wheels visible
|
||||
ENV LD_LIBRARY_PATH="/usr/local/lib/python3.10/site-packages/nvidia/cublas/lib:/usr/local/lib/python3.10/site-packages/nvidia/cudnn/lib"
|
||||
RUN pip install --no-cache-dir nvidia-cublas-cu12 nvidia-cudnn-cu12
|
||||
ENV LD_LIBRARY_PATH="/usr/local/lib/python3.10/site-packages/nvidia/cublas/lib:/usr/local/lib/python3.10/site-packages/nvidia/cudnn/lib:/usr/local/lib/python3.10/site-packages/torch/lib:${LD_LIBRARY_PATH}"
|
||||
|
||||
COPY whisper_live /app/whisper_live
|
||||
COPY run_server.py /app
|
||||
COPY hybrid_server.py /app
|
||||
|
||||
# Copy application files
|
||||
EXPOSE ${PORT_WHISPERLIVE}
|
||||
ARG PORT_WHISPERLIVE
|
||||
ENV PORT_WHISPERLIVE=${PORT_WHISPERLIVE}
|
||||
ARG FASTERWHISPER_MODEL
|
||||
ENV FASTERWHISPER_MODEL=${FASTERWHISPER_MODEL}
|
||||
# Expose both WebSocket and HTTP ports
|
||||
EXPOSE 5000 8080
|
||||
|
||||
CMD ["python3", "-u", "run_server.py", "--port", "${PORT_WHISPERLIVE}", "--backend", "faster_whisper"]
|
||||
# Use the hybrid server by default
|
||||
CMD python3 -u hybrid_server.py --websocket-port 5000 --http-port 8080 --backend faster_whisper
|
||||
|
||||
# CMD ["python3", "-u", "run_server.py", "--port", "${PORT_WHISPERLIVE}", "--backend", "faster_whisper", "--faster_whisper_custom_model_path", "/app/models/${FASTERWHISPER_MODEL}", "--ssl_cert_path", "/app/ssl"]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user