Skip to content

Commit

Permalink
Fix and update frontend Dockerfile
Browse files Browse the repository at this point in the history
- Update node image to node 21
- Copy project.inlang before running npm ci
  • Loading branch information
nas-tabchiche committed Feb 14, 2024
1 parent e0ff2d4 commit 935ab15
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions frontend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
FROM node:18-alpine AS builder
FROM node:21-alpine AS builder
WORKDIR /app

ARG PUBLIC_BACKEND_API_URL
ENV PUBLIC_BACKEND_API_URL=$PUBLIC_BACKEND_API_URL

COPY package*.json .
COPY project.inlang/ .
RUN npm ci
COPY . .
RUN npm run build
RUN npm prune --production

FROM node:18-alpine
FROM node:21-alpine
WORKDIR /app
COPY --from=builder /app/build build/
COPY --from=builder /app/node_modules node_modules/
Expand Down

0 comments on commit 935ab15

Please sign in to comment.