feat: add configuration documentation for OneDrive and OpenDAL storage integration
This commit is contained in:
+10
-16
@@ -1,7 +1,6 @@
|
||||
# 第一阶段:构建前端主题
|
||||
FROM node:18-alpine AS frontend-builder
|
||||
|
||||
# 安装 git
|
||||
RUN apk add --no-cache git
|
||||
|
||||
WORKDIR /build
|
||||
@@ -23,27 +22,22 @@ FROM python:3.12-slim-bookworm
|
||||
LABEL author="Lan"
|
||||
LABEL email="xzu@live.com"
|
||||
|
||||
# 将当前目录下的文件复制到容器的 /app 目录
|
||||
COPY . /app
|
||||
|
||||
# 设置时区为亚洲/上海
|
||||
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone
|
||||
|
||||
# 设置工作目录
|
||||
WORKDIR /app
|
||||
|
||||
# 删除不必要的目录,减少镜像体积
|
||||
RUN rm -rf docs fcb-fronted
|
||||
# 复制项目文件(通过 .dockerignore 排除不必要的文件)
|
||||
COPY . .
|
||||
|
||||
# 设置时区
|
||||
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
|
||||
echo 'Asia/Shanghai' > /etc/timezone
|
||||
|
||||
# 从构建阶段复制编译好的前端主题
|
||||
COPY --from=frontend-builder /build/fronted-2024/dist /app/themes/2024
|
||||
COPY --from=frontend-builder /build/fronted-2023/dist /app/themes/2023
|
||||
COPY --from=frontend-builder /build/fronted-2024/dist ./themes/2024
|
||||
COPY --from=frontend-builder /build/fronted-2023/dist ./themes/2023
|
||||
|
||||
# 安装依赖
|
||||
RUN pip install -r requirements.txt
|
||||
# 安装 Python 依赖
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# 暴露端口
|
||||
EXPOSE 12345
|
||||
|
||||
# 启动应用
|
||||
CMD ["python", "main.py"]
|
||||
Reference in New Issue
Block a user