Skip to content

Commit

Permalink
fix: tweak dockerfile to use mirror
Browse files Browse the repository at this point in the history
  • Loading branch information
Cubelrti authored Mar 3, 2023
1 parent 2314ffe commit f638187
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,18 @@ RUN mvn -s /app/settings.xml -f /app/pom.xml clean package
# 选择运行时基础镜像
FROM alpine:3.13

# 容器默认时区为UTC,如需使用上海时间请启用以下时区设置命令
# RUN apk add tzdata && cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo Asia/Shanghai > /etc/timezone

# 使用 HTTPS 协议访问容器云调用证书安装
RUN apk add ca-certificates

# 安装依赖包,如需其他依赖包,请到alpine依赖包管理(https://pkgs.alpinelinux.org/packages?name=php8*imagick*&branch=v3.13)查找。
# 选用国内镜像源以提高下载速度
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.tencent.com/g' /etc/apk/repositories \
&& apk add --update --no-cache openjdk8-jre-base \
&& rm -f /var/cache/apk/*

# 容器默认时区为UTC,如需使用上海时间请启用以下时区设置命令
# RUN apk add tzdata && cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo Asia/Shanghai > /etc/timezone

# 使用 HTTPS 协议访问容器云调用证书安装
RUN apk add ca-certificates

# 指定运行时的工作目录
WORKDIR /app

Expand Down

0 comments on commit f638187

Please sign in to comment.