f
This commit is contained in:
@@ -24,7 +24,7 @@ FROM alpine:3.19
|
||||
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories \
|
||||
&& apk update --no-cache \
|
||||
# 基础运行环境
|
||||
&& apk add --no-cache ca-certificates tzdata \
|
||||
&& apk add --no-cache ca-certificates tzdata fontconfig \
|
||||
# chromedp 所需的 Chromium 浏览器及依赖
|
||||
&& apk add --no-cache \
|
||||
chromium \
|
||||
@@ -46,6 +46,10 @@ COPY --from=builder /app/main /app/main
|
||||
COPY --from=builder /app/etc /app/etc
|
||||
COPY --from=builder /app/static /app/static
|
||||
|
||||
# 将自定义字体资源拷贝到系统字体目录,供 Chromium 渲染中文使用(如果存在)
|
||||
COPY resource /usr/share/fonts/custom
|
||||
RUN fc-cache -f || true
|
||||
|
||||
# 报告 PDF 缓存目录(与配置中的 ./data/report-pdf 对应)
|
||||
RUN mkdir -p /app/data/report-pdf
|
||||
VOLUME ["/app/data/report-pdf"]
|
||||
|
||||
BIN
resource/simhei.ttf
Normal file
BIN
resource/simhei.ttf
Normal file
Binary file not shown.
Reference in New Issue
Block a user