rag-frontend/Dockerfile
向宁 e2734d1091 fix: disable lefthook during Docker build with LEFTHOOK=0
Build context lacks .git directory, causing lefthook install to fail
2026-05-17 19:49:52 +08:00

18 lines
421 B
Docker

FROM node:22-alpine AS build
WORKDIR /app
RUN apk add --no-cache git
RUN corepack enable && corepack prepare pnpm@10 --activate
COPY pnpm-lock.yaml pnpm-workspace.yaml package.json ./
COPY . .
ENV LEFTHOOK=0
RUN pnpm install --frozen-lockfile
RUN pnpm run build:antd
FROM nginx:alpine AS runtime
COPY --from=build /app/apps/web-antd/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80