forked from optuna/optuna
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
29 lines (22 loc) · 912 Bytes
/
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
ARG PYTHON_VERSION=3.7
FROM python:${PYTHON_VERSION}
ENV PIP_OPTIONS "--no-cache-dir --progress-bar off"
RUN apt-get update \
&& apt-get -y install openmpi-bin libopenmpi-dev \
&& rm -rf /var/lib/apt/lists/* \
&& pip install --no-cache-dir -U pip \
&& pip install ${PIP_OPTIONS} -U setuptools
WORKDIR /workspaces
COPY . .
ARG BUILD_TYPE='dev'
RUN if [ "${BUILD_TYPE}" = "dev" ]; then \
if [ "${PYTHON_VERSION}" \< "3.6" ]; then \
pip install ${PIP_OPTIONS} -e '.[doctest, document, example, testing]' -f https://download.pytorch.org/whl/torch_stable.html; \
else \
pip install ${PIP_OPTIONS} -e '.[checking, doctest, document, example, testing]' -f https://download.pytorch.org/whl/torch_stable.html; \
fi \
else \
pip install ${PIP_OPTIONS} -e .; \
fi \
&& pip install ${PIP_OPTIONS} jupyter notebook
ENV PIP_OPTIONS ""