-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile
57 lines (46 loc) · 1.25 KB
/
Dockerfile
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
46
47
48
49
50
51
52
53
54
55
56
57
FROM ubuntu:18.04
RUN mkdir /formatml
WORKDIR /formatml
ARG DEBIAN_FRONTEND=noninteractive
ENV FORMATML_BBLFSHD_NAME formatml_bblfshd
ENV FORMATML_BBLFSHD_PORT 9432
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
apt-utils \
ca-certificates \
locales \
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen \
&& locale-gen \
&& apt-get remove -y .*-doc .*-man >/dev/null \
&& apt-get autoremove --purge -y \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
libxml2 \
libxml2-dev \
gcc \
g++ \
python3.7 \
python3.7-dev \
python3-distutils \
wget \
&& wget -O - https://bootstrap.pypa.io/get-pip.py | python3.7 \
&& pip3.7 install --no-cache-dir -r requirements.txt \
&& apt-get remove -y \
libxml2-dev \
gcc \
g++ \
python3.7-dev \
wget \
&& apt-get remove -y .*-doc .*-man >/dev/null \
&& apt-get autoremove --purge -y \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
COPY setup.py .
COPY README.md .
COPY formatml ./formatml
RUN pip3.7 install --no-cache-dir .
ENTRYPOINT ["formatml"]