统一时间格式和时区

This commit is contained in:
yml2213
2026-07-31 12:57:17 +08:00
parent 667bfbde06
commit 949a0eb8f7
24 changed files with 342 additions and 49 deletions
+8
View File
@@ -1,6 +1,7 @@
ARG NODE_BUILDER_IMAGE=docker.m.daocloud.io/library/node:22-alpine
ARG CADDY_BASE_IMAGE=docker.m.daocloud.io/library/caddy:2-alpine
ARG NPM_REGISTRY=https://registry.npmmirror.com
ARG ALPINE_MIRROR=https://mirrors.aliyun.com/alpine
FROM ${NODE_BUILDER_IMAGE} AS frontend-builder
@@ -18,6 +19,13 @@ RUN npm run build
FROM ${CADDY_BASE_IMAGE}
ARG ALPINE_MIRROR
ENV TZ=Asia/Shanghai
RUN sed -i "s|https://dl-cdn.alpinelinux.org/alpine|${ALPINE_MIRROR}|g; s|http://dl-cdn.alpinelinux.org/alpine|${ALPINE_MIRROR}|g" /etc/apk/repositories \
&& apk --no-cache add tzdata \
&& ln -snf "/usr/share/zoneinfo/${TZ}" /etc/localtime \
&& echo "${TZ}" >/etc/timezone
COPY Caddyfile /etc/caddy/Caddyfile
COPY --from=frontend-builder /app/frontend/dist /usr/share/caddy