From a752d158ca6bc95fa08f3d6dbf858b8d5fd88601 Mon Sep 17 00:00:00 2001 From: Cayman Date: Thu, 27 Jul 2023 12:51:27 -0400 Subject: [PATCH] chore: downgrade docker nodejs to 18 (#5812) --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5a9541e06f1a..346fffd117dc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ # --platform=$BUILDPLATFORM is used build javascript source with host arch # Otherwise TS builds on emulated archs and can be extremely slow (+1h) -FROM --platform=${BUILDPLATFORM:-amd64} node:20-alpine as build_src +FROM --platform=${BUILDPLATFORM:-amd64} node:18-alpine as build_src ARG COMMIT WORKDIR /usr/app RUN apk update && apk add --no-cache g++ make python3 && rm -rf /var/cache/apk/* @@ -21,7 +21,7 @@ RUN cd packages/cli && GIT_COMMIT=${COMMIT} yarn write-git-data # Copy built src + node_modules to build native packages for archs different than host. # Note: This step is redundant for the host arch -FROM node:20-alpine as build_deps +FROM node:18-alpine as build_deps WORKDIR /usr/app RUN apk update && apk add --no-cache g++ make python3 && rm -rf /var/cache/apk/* @@ -35,7 +35,7 @@ RUN cd node_modules/classic-level && yarn rebuild # Copy built src + node_modules to a new layer to prune unnecessary fs # Previous layer weights 7.25GB, while this final 488MB (as of Oct 2020) -FROM node:20-alpine +FROM node:18-alpine WORKDIR /usr/app COPY --from=build_deps /usr/app .