Spaces:
Sleeping
Sleeping
Arseniy Savin commited on
Commit ·
95086c6
1
Parent(s): cf9d4ce
Update Dockerfile to parameterize model selection for Whisper.cpp server
Browse filesRevised the Dockerfile to allow dynamic model selection via an ARG variable, enhancing flexibility in model usage during container execution.
18 unmodified lines19202122232425264 unmodified lines3132333418 unmodified lines-E 'CFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE' \-E 'CXXFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE'RUN bash ./models/download-ggml-model.sh tiny.enFROM alpine:3.21 AS runtime4 unmodified linesCOPY --from=builder /build/whisper.cpp/build/ /build/whisper.cpp/build/COPY --from=builder /build/whisper.cpp/models/ ./models/CMD sh -c "/build/whisper.cpp/build/bin/whisper-server -m /app/models/ggml-tiny.en.bin --host 0.0.0.0 --port ${PORT:-7860}"18 unmodified lines1920212223242526274 unmodified lines3233343518 unmodified lines-E 'CFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE' \-E 'CXXFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE'ARG MODEL=small.enRUN bash ./models/download-ggml-model.sh ${MODEL}FROM alpine:3.21 AS runtime4 unmodified linesCOPY --from=builder /build/whisper.cpp/build/ /build/whisper.cpp/build/COPY --from=builder /build/whisper.cpp/models/ ./models/CMD sh -c "/build/whisper.cpp/build/bin/whisper-server -m /app/models/ggml-${MODEL}.bin --host 0.0.0.0 --port ${PORT:-7860}"
Dockerfile+3-2