-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
45 lines (33 loc) · 1.21 KB
/
Dockerfile
File metadata and controls
45 lines (33 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
FROM python:3.8-slim AS build-stage
ARG DEBIAN_FRONTEND=noninteractive
ENV PIP_ROOT_USER_ACTION=ignore
COPY tts_client_python /tts-client-python/tts_client_python
COPY setup.py pyproject.toml README.md /tts-client-python/
WORKDIR /tts-client-python
# hadolint ignore=DL3008
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
libportaudio2 \
python3-pip \
python3-dev \
&& apt-get clean \
&& rm -fr /var/lib/apt/lists/* \
&& rm -fr /var/cache/apt/*
# hadolint ignore=DL3013
RUN pip install --no-cache-dir --upgrade pip \
&& pip install --no-cache-dir .
FROM python:3.8-slim
LABEL maintainer="Techmo sp. z o.o. <https://github.com/techmo-pl>"
# hadolint ignore=DL3008
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
libportaudio2 \
&& apt-get clean \
&& rm -fr /var/lib/apt/lists/* \
&& rm -fr /var/cache/apt/*
COPY --from=build-stage /usr/local/lib/python3.8/site-packages /usr/local/lib/python3.8/site-packages
COPY --from=build-stage /tts-client-python/tts_client_python /tts-client-python/tts_client_python
WORKDIR /tts-client-python
COPY ./docker-entrypoint.sh /
ENTRYPOINT ["/docker-entrypoint.sh"]