-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
44 lines (32 loc) · 909 Bytes
/
Dockerfile
File metadata and controls
44 lines (32 loc) · 909 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# ── Build stage ──
FROM node:22-slim AS build
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci
COPY . .
ARG BASE_PATH=""
ENV BASE_PATH=$BASE_PATH
ENV NEXT_PUBLIC_BASE_PATH=$BASE_PATH
RUN npm run build
# ── Runtime stage ──
FROM node:22-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
libreoffice-writer \
python3 \
curl \
ca-certificates \
&& rm -rf /var/lib/apt/lists/*
RUN curl -LsSf https://astral.sh/uv/install.sh | sh
ENV PATH="/root/.local/bin:$PATH"
WORKDIR /app
COPY --from=build /app/.next/standalone ./
COPY --from=build /app/.next/static ./.next/static
COPY --from=build /app/public ./public
COPY --from=build /app/messages ./messages
COPY --from=build /app/scripts ./scripts
ENV NODE_ENV=production
ENV LIBREOFFICE_PATH=/usr/bin/libreoffice
ENV LOCAL_AI=ner
ENV PORT=3000
EXPOSE 3000
CMD ["node", "server.js"]