Pin Node.js base image to specific digest
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
# Use lightweight Node.js 20 base image
|
||||
FROM node:20-alpine as builder
|
||||
FROM node:20-alpine@sha256:9bef0ef1e268f60627da9ba7d7605e8831d5b56ad07487d24d1aa386336d1944 as builder
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /app
|
||||
@@ -17,7 +17,7 @@ COPY . .
|
||||
RUN npm run build
|
||||
|
||||
# Use a minimal base image for running the app
|
||||
FROM node:20-alpine
|
||||
FROM node:20-alpine@sha256:9bef0ef1e268f60627da9ba7d7605e8831d5b56ad07487d24d1aa386336d1944
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
|
||||
Reference in New Issue
Block a user