From 3413cd5cea8731b44e7e4288286c766fef963022 Mon Sep 17 00:00:00 2001 From: Zahin Mohammad Date: Wed, 21 Oct 2026 16:18:28 -0400 Subject: [PATCH 1/3] feat(docker): upgrade node runtime to 24.22.1 Move the builder, production and integration-tests images, .nvmrc and the CI node-version pins from 22.23.4 to 24.22.1 with the re-resolved node:24.22.1-alpine digest, matching the Node 24 move in BitGoJS. Node 24 sizes its default heap at about 2.2 GB in the test container and ts-node compilation exhausts it, so the integration runner caps the heap explicitly with --max-old-space-size=3072. Ticket: WCN-3304 Co-Authored-By: Claude Sonnet 5.5 --- .github/workflows/build-and-test.yaml | 2 +- .github/workflows/pull_request.yaml | 4 ++-- .nvmrc | 2 +- Dockerfile | 12 ++++++------ integration-tests.Dockerfile | 7 +++++-- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index c360e16f..ce84e7b5 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -6,7 +6,7 @@ on: node-version: description: 'Node.js version to use' type: string - default: '22.23.4' + default: '24.22.1' secrets: fossa-api-key: description: 'API key used for Fossa scan' diff --git a/.github/workflows/pull_request.yaml b/.github/workflows/pull_request.yaml index cf185d04..760e1180 100644 --- a/.github/workflows/pull_request.yaml +++ b/.github/workflows/pull_request.yaml @@ -28,7 +28,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: '22.23.4' + node-version: '24.22.1' cache: 'npm' - name: Cache dependencies @@ -78,7 +78,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v6 with: - node-version: '22.23.4' + node-version: '24.22.1' cache: 'npm' - name: Install dependencies diff --git a/.nvmrc b/.nvmrc index b8b23ca9..ce62013c 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -22.23.4 +24.22.1 diff --git a/Dockerfile b/Dockerfile index 9713aac0..a8004c0e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,10 @@ # syntax=docker/dockerfile:1.4 # Build stage -# Using node:22.23.4-alpine (October 2026 Node.js security release) +# Using node:24.22.1-alpine (October 2026 Node.js security release) # Pinned to AMD64-specific SHA256 digest for supply chain security and deterministic builds -# To update: docker pull --platform linux/amd64 node:22.23.4-alpine && docker inspect --format='{{index .RepoDigests 0}}' node:22.23.4-alpine -FROM node:22.23.4-alpine@sha256:ce8d97f7cfc7c5386421eb932df20a29df99b1a7f469f6157d5c9956702ffadc AS builder +# To update: docker pull --platform linux/amd64 node:24.22.1-alpine && docker inspect --format='{{index .RepoDigests 0}}' node:24.22.1-alpine +FROM node:24.22.1-alpine@sha256:6a1c190e17215d844926b0677f4bf87273ff7d5e54db06d3b5b5863ab0b09a3d AS builder # Set build-time variables for reproducibility ARG NODE_ENV=development @@ -15,7 +15,7 @@ ARG PORT=3081 # Set environment variables ENV NODE_ENV=${NODE_ENV} \ - NODE_VERSION=22.23.4 + NODE_VERSION=24.22.1 # Set build-time labels LABEL org.opencontainers.image.created=${BUILD_DATE} \ @@ -54,9 +54,9 @@ COPY . . RUN npm run build # Production stage -# Using node:22.23.4-alpine (October 2026 Node.js security release) +# Using node:24.22.1-alpine (October 2026 Node.js security release) # Pinned to AMD64-specific SHA256 digest for supply chain security and deterministic builds -FROM node:22.23.4-alpine@sha256:ce8d97f7cfc7c5386421eb932df20a29df99b1a7f469f6157d5c9956702ffadc AS production +FROM node:24.22.1-alpine@sha256:6a1c190e17215d844926b0677f4bf87273ff7d5e54db06d3b5b5863ab0b09a3d AS production # Declare build arguments in production stage ARG PORT=3081 diff --git a/integration-tests.Dockerfile b/integration-tests.Dockerfile index bf4de996..65e1d7b1 100644 --- a/integration-tests.Dockerfile +++ b/integration-tests.Dockerfile @@ -1,5 +1,5 @@ # Stage 1 — build -FROM node:22.23.4-alpine@sha256:ce8d97f7cfc7c5386421eb932df20a29df99b1a7f469f6157d5c9956702ffadc AS builder +FROM node:24.22.1-alpine@sha256:6a1c190e17215d844926b0677f4bf87273ff7d5e54db06d3b5b5863ab0b09a3d AS builder ENV NODE_ENV=test \ TZ=UTC \ @@ -19,9 +19,12 @@ COPY . . RUN npm run build # Stage 2 — test runner -FROM node:22.23.4-alpine@sha256:ce8d97f7cfc7c5386421eb932df20a29df99b1a7f469f6157d5c9956702ffadc AS runner +FROM node:24.22.1-alpine@sha256:6a1c190e17215d844926b0677f4bf87273ff7d5e54db06d3b5b5863ab0b09a3d AS runner +# Node 24 sizes its default heap from container memory and ts-node compilation +# exhausts it, getting the suite OOM-killed; an explicit cap keeps GC working. ENV NODE_ENV=test \ + NODE_OPTIONS=--max-old-space-size=3072 \ TZ=UTC \ LANG=C.UTF-8 From 035ab5c3b746627f0c50de16ec168e055fd28778 Mon Sep 17 00:00:00 2001 From: Zahin Mohammad Date: Wed, 21 Oct 2026 16:29:58 -0400 Subject: [PATCH 2/3] docs(docker): update README node prerequisite to 24.22.1 Ticket: WCN-3304 Co-Authored-By: Claude Sonnet 5.5 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 6709627b..d785a9c5 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ When a backup AWM URL **is** provided, dedicated mTLS certificates for the backu ### Prerequisites -- **Node.js** 22.23.4 or higher. +- **Node.js** 24.22.1 or higher. - **npm** or **yarn** package manager. - **OpenSSL** for certificate generation. - **Docker** and **Docker Compose** for containerized deployment (or you can use **Podman** as alternative to Docker). From 541aec5e7600e7d879d09dcd540a674f07c3e879 Mon Sep 17 00:00:00 2001 From: Zahin Mohammad Date: Fri, 23 Oct 2026 13:36:15 -0400 Subject: [PATCH 3/3] fix(gha): address Node 24 review feedback Read the Node.js version from .nvmrc in the remaining GitHub Actions workflows and match the integration runner heap cap to continuous integration. Ticket: WCN-3304 --- .github/workflows/audit-api-spec.yaml | 4 ++-- .github/workflows/release-to-ghcr.yaml | 4 ++-- integration-tests.Dockerfile | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/audit-api-spec.yaml b/.github/workflows/audit-api-spec.yaml index 4ca50773..892487b6 100644 --- a/.github/workflows/audit-api-spec.yaml +++ b/.github/workflows/audit-api-spec.yaml @@ -18,7 +18,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v6 with: - node-version: 22 + node-version-file: .nvmrc - name: Cache npm dependencies id: node-modules-cache @@ -71,7 +71,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v6 with: - node-version: 22 + node-version-file: .nvmrc - name: Cache npm dependencies id: node-modules-cache diff --git a/.github/workflows/release-to-ghcr.yaml b/.github/workflows/release-to-ghcr.yaml index 55c69bac..ade3e494 100644 --- a/.github/workflows/release-to-ghcr.yaml +++ b/.github/workflows/release-to-ghcr.yaml @@ -30,7 +30,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v6 with: - node-version: '22' + node-version-file: .nvmrc - name: Install dependencies run: npm ci @@ -66,7 +66,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v6 with: - node-version: '22' + node-version-file: .nvmrc - name: Install dependencies run: npm ci diff --git a/integration-tests.Dockerfile b/integration-tests.Dockerfile index 65e1d7b1..3d4ae500 100644 --- a/integration-tests.Dockerfile +++ b/integration-tests.Dockerfile @@ -24,7 +24,7 @@ FROM node:24.22.1-alpine@sha256:6a1c190e17215d844926b0677f4bf87273ff7d5e54db06d3 # Node 24 sizes its default heap from container memory and ts-node compilation # exhausts it, getting the suite OOM-killed; an explicit cap keeps GC working. ENV NODE_ENV=test \ - NODE_OPTIONS=--max-old-space-size=3072 \ + NODE_OPTIONS=--max-old-space-size=4096 \ TZ=UTC \ LANG=C.UTF-8