Skip to content

Commit 4f5a9a9

Browse files
committed
refactor: simplify Dockerfile by removing redundant mirror configurations and cleaning up package installation commands
1 parent 41e7e68 commit 4f5a9a9

File tree

2 files changed

+5
-9
lines changed

2 files changed

+5
-9
lines changed

scripts/images/backend/Dockerfile

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
FROM maven:3-openjdk-8-slim AS datax-builder
22

3-
RUN sed -i 's/deb.debian.org/mirrors.aliyun.com/g' /etc/apt/sources.list && \
4-
sed -i 's/security.debian.org/mirrors.aliyun.com/g' /etc/apt/sources.list && \
5-
apt-get update && \
3+
RUN apt-get update && \
64
apt-get install -y git && \
75
git clone https://github.com/alibaba/DataX.git
86

@@ -24,8 +22,7 @@ RUN cd /opt/backend && \
2422

2523
FROM openjdk:21-jdk-slim
2624

27-
RUN sed -i 's/deb.debian.org/mirrors.aliyun.com/g' /etc/apt/sources.list.d/debian.sources && \
28-
apt-get update && \
25+
RUN apt-get update && \
2926
apt-get install -y vim wget curl nfs-common rsync python3 python3-pip python-is-python3 dos2unix && \
3027
apt-get clean && \
3128
rm -rf /var/lib/apy/lists/*

scripts/images/runtime/Dockerfile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ COPY runtime/ops /opt/runtime/datamate/ops
55

66
ENV PYTHONPATH=/opt/runtime/datamate/
77

8-
RUN sed -i 's/deb.debian.org/mirrors.aliyun.com/g' /etc/apt/sources.list.d/debian.sources \
9-
&& apt update \
8+
RUN apt update \
109
&& apt install -y libgl1 libglib2.0-0 vim poppler-utils tesseract-ocr tesseract-ocr-chi-sim libmagic1t64 libreoffice\
1110
&& apt clean \
1211
&& rm -rf /var/lib/apt/lists/*
@@ -15,8 +14,8 @@ WORKDIR /opt/runtime
1514

1615
ENV HF_HUB_DISABLE_XET=1
1716

18-
RUN pip install -e . -i https://mirrors.aliyun.com/pypi/simple/ \
19-
&& pip install -r /opt/runtime/datamate/ops/requirements.txt -i https://mirrors.aliyun.com/pypi/simple/ \
17+
RUN pip install -e . \
18+
&& pip install -r /opt/runtime/datamate/ops/requirements.txt \
2019
&& pip cache purge
2120

2221
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

0 commit comments

Comments
 (0)