Skip to content

Commit

Permalink
build: remove NODE_OPTIONS
Browse files Browse the repository at this point in the history
  • Loading branch information
QuCMGisaia committed Dec 19, 2024
1 parent d6c657f commit 765f3ac
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
### STAGE 1: Build ###

# We label our stage as 'builder'
FROM node:18.20.5 as builder
FROM node:18.20.5 AS builder

COPY ./package.json ./
COPY ./package-lock.json ./

RUN npm set progress=false && npm config set depth 0 && npm cache clean --force

## Storing node modules on a separate layer will prevent unnecessary npm installs at each build
RUN export NODE_OPTIONS=--max_old_space_size=8192 && npm i && mkdir /ng-app && cp -R ./node_modules ./ng-app
RUN npm i && mkdir /ng-app && cp -R ./node_modules ./ng-app

COPY ./scripts/start.sh ./ng-app
COPY ./scripts/fetch-conf-by-http.sh ./ng-app
Expand All @@ -19,7 +19,7 @@ WORKDIR /ng-app
COPY . .

## Build the angular app in production mode and store the artifacts in dist folder
RUN export NODE_OPTIONS=--max_old_space_size=8192 && npm run build
RUN npm run build

### STAGE 2: Setup ###

Expand Down

0 comments on commit 765f3ac

Please sign in to comment.