-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile.cpu
39 lines (29 loc) · 1.74 KB
/
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
37
38
39
FROM ubuntu:18.04 as dev-stage
WORKDIR /usr/src/app
ENV LANG="C.UTF-8" LC_ALL="C.UTF-8" PATH="/opt/venv/bin:$PATH" PIP_NO_CACHE_DIR="false" DISPLAY=":0" CXXFLAGS="-I/opt/venv/lib/python3.6/site-packages/numpy/core/include"
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
python3 python3-pip python3-venv python3-dev build-essential zlib1g-dev libsdl2-dev libjpeg-dev \
wget nasm tar libbz2-dev libgtk2.0-dev cmake git libfluidsynth-dev libgme-dev \
libopenal-dev timidity libwildmidi-dev unzip libboost-all-dev libcanberra-gtk-module \
libopenmpi-dev libosmesa6-dev libgl1-mesa-glx libglfw3 && \
rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN python3 -m venv /opt/venv && \
python3 -m pip install pip==19.3.1 pip-tools==4.2.0 setuptools==44.0.0
RUN echo "https://download.pytorch.org/whl/cpu/torch-1.3.0%2Bcpu-cp36-cp36m-linux_x86_64.whl \
--hash=sha256:ce648bb0c6b86dd99a8b5598ae6362a066cca8de69ad089cd206ace3bdec0a5f \
\n \
https://download.pytorch.org/whl/cpu/torchvision-0.4.1%2Bcpu-cp36-cp36m-linux_x86_64.whl \
--hash=sha256:593ad12c3c8ce16068566c9eb2bfb39f4834c89a2cc9f0b181e9121b06046b3e \
\n" >> requirements.txt
RUN python3 -m piptools sync
RUN wget https://github.com/openai/baselines/archive/9ee399f5b20cd70ac0a871927a6cf043b478193f.zip -O baselines.zip && \
unzip baselines.zip && \
cd baselines*/ && \
python3 -m pip install . && \
cd ../ && \
rm -rf baselines*
COPY . .
RUN python3 -m venv /opt/venv && \
python3 -m pip install Pillow==6.2.1 && \
python3 -m pip install -e .