Skip to content

Commit 7ca44c8

Browse files
committed
fix: pin docker image to sha2 digest
Ticket: WP-6406
1 parent b855204 commit 7ca44c8

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Dockerfile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@
22

33
# Build stage
44
# Using node:22-alpine with OpenSSL 3.3.2+ to address CVE-2024-6119
5-
FROM node:22-alpine AS builder
5+
# Pinned to specific SHA256 digest for supply chain security and deterministic builds
6+
# To update: podman pull node:22-alpine && podman inspect node:22-alpine --format '{{index .RepoDigests 0}}'
7+
# Last updated: 2025-10-24
8+
FROM node:22-alpine@sha256:d31216005bd330aa47f848822d4f269f6c79f0905b60cca1d87577149519daa6 AS builder
69

710
# Set build-time variables for reproducibility
811
ARG NODE_ENV=development
@@ -51,8 +54,10 @@ COPY . .
5154
# Build TypeScript code with deterministic output
5255
RUN npm run build
5356

57+
# Production stage
5458
# Using node:22-alpine with OpenSSL 3.3.2+ to address CVE-2024-6119
55-
FROM node:22-alpine AS production
59+
# Pinned to specific SHA256 digest for supply chain security and deterministic builds
60+
FROM node:22-alpine@sha256:d31216005bd330aa47f848822d4f269f6c79f0905b60cca1d87577149519daa6 AS production
5661

5762
# Declare build arguments in production stage
5863
ARG PORT=3081

0 commit comments

Comments
 (0)