Skip to content

Commit 8c46862

Browse files
committed
docker
1 parent 75d94e8 commit 8c46862

File tree

2 files changed

+11
-55
lines changed

2 files changed

+11
-55
lines changed

Dockerfile

Lines changed: 1 addition & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,4 @@
1-
FROM debian:buster-slim
2-
3-
RUN apt-get update && \
4-
apt-get install -y git python3 python3-dev python3-pip curl build-essential
5-
6-
# taken from https://github.com/alphacep/vosk-server/blob/master/docker
7-
RUN apt-get update && \
8-
apt-get install -y --no-install-recommends \
9-
wget \
10-
bzip2 \
11-
unzip \
12-
xz-utils \
13-
g++ \
14-
make \
15-
cmake \
16-
python3-websockets \
17-
python3-setuptools \
18-
python3-wheel \
19-
python3-cffi \
20-
zlib1g-dev \
21-
automake \
22-
autoconf \
23-
libtool \
24-
pkg-config \
25-
ca-certificates \
26-
&& rm -rf /var/lib/apt/lists/*
27-
28-
RUN \
29-
git clone -b vosk --single-branch https://github.com/alphacep/kaldi /opt/kaldi \
30-
&& cd /opt/kaldi/tools \
31-
&& sed -i 's:status=0:exit 0:g' extras/check_dependencies.sh \
32-
&& sed -i 's:--enable-ngram-fsts:--enable-ngram-fsts --disable-bin:g' Makefile \
33-
&& make -j $(nproc) openfst cub \
34-
&& if [ "x$KALDI_MKL" != "x1" ] ; then \
35-
extras/install_openblas_clapack.sh; \
36-
else \
37-
extras/install_mkl.sh; \
38-
fi \
39-
\
40-
&& cd /opt/kaldi/src \
41-
&& if [ "x$KALDI_MKL" != "x1" ] ; then \
42-
./configure --mathlib=OPENBLAS_CLAPACK --shared; \
43-
else \
44-
./configure --mathlib=MKL --shared; \
45-
fi \
46-
&& sed -i 's:-msse -msse2:-msse -msse2:g' kaldi.mk \
47-
&& sed -i 's: -O1 : -O3 :g' kaldi.mk \
48-
&& make -j $(nproc) online2 lm rnnlm \
49-
\
50-
&& git clone https://github.com/alphacep/vosk-api /opt/vosk-api \
51-
&& cd /opt/vosk-api/src \
52-
&& KALDI_MKL=$KALDI_MKL KALDI_ROOT=/opt/kaldi make -j $(nproc) \
53-
&& cd /opt/vosk-api/python \
54-
&& python3 ./setup.py install
1+
FROM alphacep/kaldi-vosk-server
552

563
RUN pip3 install ovos-stt-http-server==0.0.2a1
574

readme.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,13 @@ You need to download a kaldi model or provide a direct download url
4949

5050
`model` - full path or direct download url for model
5151

52-
`lang` - optional, if `model` not provided will download default small model (if it exists)
52+
`lang` - optional, if `model` not provided will download default small model (if it exists)
53+
54+
55+
## Docker
56+
57+
This plugin can be used together with [ovos-stt-http-server](https://github.com/OpenVoiceOS/ovos-stt-http-server)
58+
59+
```bash
60+
docker run -p 8080:8080 ghcr.io/openvoiceos/vosk-stt-http-server:master
61+
```

0 commit comments

Comments
 (0)