-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile.layer2
More file actions
43 lines (35 loc) · 1.35 KB
/
Dockerfile.layer2
File metadata and controls
43 lines (35 loc) · 1.35 KB
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
# Layer 2: pyBench Image
# USER-AGNOSTIC: No user creation — Layer 3 handles user setup
ARG BASE_IMAGE=dev-bench-base:latest
FROM ${BASE_IMAGE}
LABEL layer="2"
LABEL layer.name="py-bench"
LABEL layer.version="2.0.3"
LABEL layer.description="Python development tools (user-agnostic)"
LABEL bench.type="python"
# Everything runs as root
USER root
# Install Python 3.12 and tools
RUN apt-get update && apt-get install -y \
python3.12 \
python3.12-venv \
python3.12-dev \
python3-pip \
libomp5 \
libnuma1 \
&& rm -rf /var/lib/apt/lists/*
# Install pipx, poetry, and common Python tools
RUN python3 -m pip install --break-system-packages \
pipx poetry black flake8 mypy pytest pytest-cov coverage pysonar ipython jupyter \
django flask fastapi uvicorn pandas numpy
# Install GitLab CLI (glab)
RUN apt-get update && apt-get install -y glab && rm -rf /var/lib/apt/lists/*
COPY scripts/check-amd-rocm-wsl /usr/local/bin/check-amd-rocm-wsl
RUN chmod +x /usr/local/bin/check-amd-rocm-wsl && \
if [ ! -e /usr/lib/x86_64-linux-gnu/libomp.so ] && [ -e /usr/lib/x86_64-linux-gnu/libomp.so.5 ]; then \
ln -s /usr/lib/x86_64-linux-gnu/libomp.so.5 /usr/lib/x86_64-linux-gnu/libomp.so; \
fi
# Add Python path to /etc/skel/.zshrc
RUN echo 'export PATH="$HOME/.local/bin:$PATH"' >> /etc/skel/.zshrc
# Default command
CMD ["sleep", "infinity"]