first commit
All checks were successful
Deploy to Server / deploy (push) Successful in 19s

This commit is contained in:
爽哒哒
2026-03-20 23:30:57 +08:00
commit 290be5d5be
328 changed files with 37215 additions and 0 deletions

28
frontend/Dockerfile Normal file
View File

@@ -0,0 +1,28 @@
# 使用 Node 运行 preview 模式(和 market_page 一致)
FROM node:22-alpine
# 设置工作目录
WORKDIR /app
# 安装构建依赖
RUN apk add --no-cache autoconf automake libtool make g++ zlib-dev nasm python3
# 安装依赖
COPY package.json package-lock.json* ./
RUN npm install --registry=https://registry.npmmirror.com
# 复制项目文件
COPY . .
# 接收构建参数
ARG VITE_API_URL=/api
ENV VITE_API_URL=$VITE_API_URL
# 构建生产环境代码
RUN npm run build
# 暴露应用运行的端口
EXPOSE 8890
# 启动应用 (Preview 模式)
CMD ["npm", "run", "preview", "--", "--host", "0.0.0.0", "--port", "8890"]