-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile-cluster-base
61 lines (58 loc) · 1.84 KB
/
Dockerfile-cluster-base
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
58
59
60
61
FROM python:3.11-slim
ENV \
DEBIAN_FRONTEND=noninteractive \
LANG=C.UTF-8 \
LC_ALL=C.UTF-8
ARG CMAKE_VERSION="3.30.2"
ARG DASK_VERSION
RUN apt-get update && \
apt-get install -y --no-install-recommends \
build-essential \
curl \
libomp-dev && \
curl -O -L \
https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-linux-$(arch).sh && \
mkdir /opt/cmake && \
sh cmake-${CMAKE_VERSION}-linux-$(arch).sh --skip-license --prefix=/opt/cmake && \
ln -sf /opt/cmake/bin/cmake /usr/local/bin/cmake && \
pip install --no-cache-dir --prefer-binary \
blosc \
bokeh \
dask==${DASK_VERSION} \
'dask-ml>=2023.3.24' \
distributed==${DASK_VERSION} \
lz4 \
numpy \
'pandas>=2.0.0' \
scikit-learn && \
# remove unnecessary file
find \
/usr/local/lib/python3.11/site-packages \
-type f \
\( \
-name '*.c' \
-o -name '*.cc' \
-o -name '*.cpp' \
-o -name '*.h' \
-o -name '*.hpp' \
-o -wholename '*bokeh/sampledata/*' \
-o -wholename '*dask/*tests/*' \
-o -wholename '*joblib/test/*' \
-o -wholename '*llvmlite/tests/*' \
-o -wholename '*numba/*tests/*' \
-o -wholename '*numpy/*tests/*' \
-o -wholename '*pandas/*tests/*' \
-o -wholename '*scikit-learn/tests*' \
-o -wholename '*scikit-learn/*/tests*' \
-o -wholename '*scipy/*/tests*' \
-o -wholename '*tornado/test/*' \
-o -wholename '*/__pycache__/*' \
\) \
-exec rm '{}' '+' && \
find \
/usr/local/lib/python3.11/site-packages \
-type d \
-wholename '*__pycache__*' \
-exec rm -rf '{}' '+' && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*