2024-07-25 13:57:13 -04:00
|
|
|
ARG NODE_VERSION=20
|
|
|
|
ARG ALPINE_VERSION=3.19
|
|
|
|
|
|
|
|
FROM node:${NODE_VERSION}-alpine${ALPINE_VERSION} AS builder
|
|
|
|
WORKDIR /build-stage
|
|
|
|
COPY package*.json ./
|
|
|
|
RUN npm ci
|
|
|
|
# Copy the the files you need
|
|
|
|
COPY . ./
|
|
|
|
RUN npm run build
|
|
|
|
|
2024-07-25 14:23:47 -04:00
|
|
|
FROM nginx:stable-alpine${ALPINE_VERSION} AS production
|
2024-07-25 13:57:13 -04:00
|
|
|
COPY --from=builder /build-stage/build /usr/share/nginx/html/
|