From deb5f8d77e53e20e22b3055065c51ecabcb3231e Mon Sep 17 00:00:00 2001 From: fly6516 Date: Wed, 18 Dec 2024 19:16:45 +0800 Subject: [PATCH] fix seen bugs --- Dockerfile | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index aa6823a..d3d86ad 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,15 @@ -LABEL authors="fly" +# LABEL authors="fly" -ENTRYPOINT ["top", "-b"] +# ENTRYPOINT ["top", "-b"] # 使用 Ubuntu 作为基础镜像 -FROM ubuntu:20.04 +FROM dockerp.com/ubuntu:20.04 # 设置环境变量 ENV DEBIAN_FRONTEND=noninteractive # 使用南京大学的 apt 源 -RUN sed -i 's|http://archive.ubuntu.com/ubuntu/|https://mirror.nju.edu.cn/ubuntu/|g' /etc/apt/sources.list && \ - sed -i 's|http://security.ubuntu.com/ubuntu/|https://mirror.nju.edu.cn/ubuntu/|g' /etc/apt/sources.list +RUN sed -i 's/archive.ubuntu.com/mirrors.nju.edu.cn/g' /etc/apt/sources.list # 更新系统并安装常用工具 RUN apt-get update && apt-get install -y \ @@ -23,9 +22,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # 安装 Node.js(替换为南京大学的源) -RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash - && \ - sed -i 's|deb.nodesource.com|mirror.nju.edu.cn/nodesource/deb|g' /etc/apt/sources.list.d/nodesource.list && \ - apt-get update && apt-get install -y nodejs +RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \ + # sed -i 's|deb.nodesource.com|mirror.nju.edu.cn/nodesource/deb|g' /etc/apt/sources.list.d/nodesource.list && \ + apt-get update && apt-get install -y nodejs && npm config set registry https://repo.nju.edu.cn/repository/npm/ # 修改源 # 安装其他语言的编译器和工具 RUN apt-get update && apt-get install -y \