File: Dockerfile.devel

package info (click to toggle)
sphinxtrain 5.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 32,572 kB
  • sloc: ansic: 94,052; perl: 8,939; python: 6,702; cpp: 2,044; makefile: 6
file content (22 lines) | stat: -rw-r--r-- 826 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
FROM ubuntu:22.04 as runtime
# Runtime packages
RUN apt-get update && apt-get install -y --no-install-recommends \
    python3-pip python-is-python3 perl sox libfst8 libngram2
# Installing the Ubuntu packages gives us too many dependencies :(
RUN pip install --no-cache-dir numpy scipy

FROM runtime as build
# Stuff that hopefully won't change
RUN apt-get update && apt-get install -y \
    gcc g++ git cmake libfst-dev libngram-dev ninja-build
RUN git clone --depth 1 https://github.com/cmusphinx/pocketsphinx.git
WORKDIR /pocketsphinx
RUN cmake -S . -B build -G Ninja && cmake --build build --target install
RUN /sbin/ldconfig

# Set up for development
RUN useradd -UM sphinxtrain
RUN mkdir /st /work && chown sphinxtrain:sphinxtrain /st /work
RUN chown -R sphinxtrain:sphinxtrain /usr/local
WORKDIR /work
USER sphinxtrain