forked from MajorTal/DeepSpell
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Dockerfile_cpu
36 lines (24 loc) · 890 Bytes
/
Dockerfile_cpu
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
FROM tensorflow/tensorflow:latest-py3
ARG deepspell_dir=/opt/deepspell
ARG deepspell_user=deepspell
ARG deepspell_uid=1000
RUN mkdir -p ${deepspell_dir}
RUN apt-get update && apt-get install -y git locales
ARG KERAS_VERSION=1.2.2
ENV KERAS_BACKEND=tensorflow
RUN pip3 --no-cache-dir install --no-dependencies git+https://github.com/fchollet/keras.git@${KERAS_VERSION}
RUN pip3 --no-cache-dir install h5py
# dump package lists
RUN dpkg-query -l > /dpkg-query-l.txt \
&& pip3 freeze > /pip3-freeze.txt
# set locale http://jaredmarkell.com/docker-and-locales/
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
ADD / ${deepspell_dir}
RUN useradd -m -s /bin/bash -N -u ${deepspell_uid} ${deepspell_user} && \
chown ${deepspell_user} ${deepspell_dir} -R
USER ${deepspell_user}
WORKDIR ${deepspell_dir}
CMD /bin/sh /opt/deepspell/run.sh