Skip to content

Commit ea2e646

Browse files
committed
update build shell
1 parent 380cf02 commit ea2e646

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

build_sandbox_image.sh

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,17 @@ echo "Building Python sandbox Docker image..."
1212

1313
# Create a temporary Dockerfile
1414
cat > Dockerfile.sandbox << 'EOF'
15-
FROM python:3.11-slim
15+
FROM python:3.11-slim-bookworm
16+
17+
RUN echo 'deb https://mirrors.aliyun.com/debian/ bookworm main contrib non-free non-free-firmware' > /etc/apt/sources.list && \
18+
echo 'deb https://mirrors.aliyun.com/debian/ bookworm-updates main contrib non-free non-free-firmware' >> /etc/apt/sources.list && \
19+
echo 'deb https://mirrors.aliyun.com/debian-security bookworm-security main contrib non-free non-free-firmware' >> /etc/apt/sources.list && \
20+
apt-get update -o Acquire::Retries=5
1621
1722
# Install basic system utilities
18-
RUN apt-get update && apt-get install -y \
23+
RUN apt-get update -o Acquire::Retries=5 \
24+
&& apt-get install -y --no-install-recommends \
25+
ca-certificates \
1926
curl \
2027
wget \
2128
git \
@@ -26,7 +33,9 @@ RUN apt-get update && apt-get install -y \
2633
&& rm -rf /var/lib/apt/lists/*
2734
2835
# Install common Python packages
29-
RUN pip install --no-cache-dir \
36+
RUN pip install --no-cache-dir -i https://pypi.tuna.tsinghua.edu.cn/simple/ --trusted-host mirrors.aliyun.com \
37+
modelscope \
38+
datasets==3.6.0 \
3039
numpy \
3140
pandas \
3241
matplotlib \

0 commit comments

Comments
 (0)