docker update
This commit is contained in:
@ -1,9 +1,17 @@
|
|||||||
# Stage 1: Build Angular app
|
# Stage 1: Build Angular app
|
||||||
FROM node:18-alpine as build
|
FROM node:18-alpine as build
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
|
# Install build dependencies
|
||||||
|
RUN apk add --no-cache python3 make g++
|
||||||
|
|
||||||
COPY package*.json ./
|
COPY package*.json ./
|
||||||
RUN npm ci --legacy-peer-deps
|
RUN npm ci --legacy-peer-deps
|
||||||
|
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
|
# Increase Node memory and use faster build
|
||||||
|
ENV NODE_OPTIONS="--max-old-space-size=4096"
|
||||||
RUN npm run build -- --configuration production
|
RUN npm run build -- --configuration production
|
||||||
|
|
||||||
# Stage 2: Serve via Nginx
|
# Stage 2: Serve via Nginx
|
||||||
|
|||||||
Reference in New Issue
Block a user