From 94b1d665356ac1d4cc77cba215ee4fd43aa6bb6e Mon Sep 17 00:00:00 2001 From: zhikunyao Date: Thu, 18 Sep 2025 10:58:01 +0800 Subject: [PATCH] enhance: base images use https to install apt package 2.5 (#44420) pr: #44382 Signed-off-by: Zhikun Yao --- build/docker/milvus/gpu/ubuntu22.04/Dockerfile | 6 +++++- build/docker/milvus/ubuntu20.04/Dockerfile | 6 +++++- build/docker/milvus/ubuntu22.04/Dockerfile | 6 +++++- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/build/docker/milvus/gpu/ubuntu22.04/Dockerfile b/build/docker/milvus/gpu/ubuntu22.04/Dockerfile index 342c2fbbbe..b001ab7b91 100644 --- a/build/docker/milvus/gpu/ubuntu22.04/Dockerfile +++ b/build/docker/milvus/gpu/ubuntu22.04/Dockerfile @@ -2,8 +2,12 @@ FROM nvidia/cuda:11.8.0-runtime-ubuntu22.04 ARG TARGETARCH +# Install ca-certificates first, then switch to HTTPS and install other packages RUN apt-get update && \ - apt-get install -y --no-install-recommends curl ca-certificates libaio-dev libgomp1 libopenblas-dev && \ + apt-get install -y --no-install-recommends ca-certificates && \ + sed -i 's/http:/https:/g' /etc/apt/sources.list && \ + apt-get update && \ + apt-get install -y --no-install-recommends curl libaio-dev libgomp1 libopenblas-dev && \ apt-get remove --purge -y && \ rm -rf /var/lib/apt/lists/* diff --git a/build/docker/milvus/ubuntu20.04/Dockerfile b/build/docker/milvus/ubuntu20.04/Dockerfile index 8fb208605b..c002d0fb01 100644 --- a/build/docker/milvus/ubuntu20.04/Dockerfile +++ b/build/docker/milvus/ubuntu20.04/Dockerfile @@ -14,8 +14,12 @@ FROM ubuntu:focal-20240530 ARG TARGETARCH ARG MILVUS_ASAN_LIB +# Install ca-certificates first, then switch to HTTPS and install other packages RUN apt-get update && \ - apt-get install -y --no-install-recommends curl ca-certificates libaio-dev libgomp1 libopenblas-dev && \ + apt-get install -y --no-install-recommends ca-certificates && \ + sed -i 's/http:/https:/g' /etc/apt/sources.list && \ + apt-get update && \ + apt-get install -y --no-install-recommends curl libaio-dev libgomp1 libopenblas-dev && \ apt-get remove --purge -y && \ rm -rf /var/lib/apt/lists/* diff --git a/build/docker/milvus/ubuntu22.04/Dockerfile b/build/docker/milvus/ubuntu22.04/Dockerfile index ed69987c2a..61243b35f6 100644 --- a/build/docker/milvus/ubuntu22.04/Dockerfile +++ b/build/docker/milvus/ubuntu22.04/Dockerfile @@ -14,8 +14,12 @@ FROM ubuntu:jammy-20240530 ARG TARGETARCH ARG MILVUS_ASAN_LIB +# Install ca-certificates first, then switch to HTTPS and install other packages RUN apt-get update && \ - apt-get install -y --no-install-recommends curl ca-certificates libaio-dev libgomp1 libopenblas-dev && \ + apt-get install -y --no-install-recommends ca-certificates && \ + sed -i 's/http:/https:/g' /etc/apt/sources.list && \ + apt-get update && \ + apt-get install -y --no-install-recommends curl libaio-dev libgomp1 libopenblas-dev && \ apt-get remove --purge -y && \ rm -rf /var/lib/apt/lists/*