Skip to content

Commit c15aa40

Browse files
[feat] increare the docker base images for node.js, nginx for sample projects angular, react.js, vue.js (#23388)
## Description This PR updates the Docker build arguments for all front-end project guides (React.js, Angular, Vue.js) to use the latest Node.js and NGINX versions for improved security, stability, and performance. ### Changes Made - Updated Node.js version: From 22.14.0-alpine → 24.7.0-alpine - Updated NGINX version: From alpine3.21 → alpine3.22 ### Impact - Ensures projects are built on the latest stable Node.js runtime without security issues. - Provides updated NGINX base image for better performance and security patches. - Aligns Docker images across React.js, Angular, and Vue.js guides with consistent and up-to-date configurations. - [x] Technical review
1 parent 5d7168c commit c15aa40

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

content/guides/angular/containerize.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ Copy and replace the contents of your existing `Dockerfile` with the configurati
126126
# =========================================
127127
# Stage 1: Build the Angular Application
128128
# =========================================
129-
ARG NODE_VERSION=22.14.0-alpine
130-
ARG NGINX_VERSION=alpine3.21
129+
ARG NODE_VERSION=24.7.0-alpine
130+
ARG NGINX_VERSION=alpine3.22
131131

132132
# Use a lightweight Node.js image for building (customizable via ARG)
133133
FROM node:${NODE_VERSION} AS builder

content/guides/angular/develop.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Create a file named `Dockerfile.dev` in your project root with the following con
3838
# =========================================
3939

4040
# Define the Node.js version to use (Alpine for a small footprint)
41-
ARG NODE_VERSION=22.14.0-alpine
41+
ARG NODE_VERSION=24.7.0-alpine
4242

4343
# Set the base image for development
4444
FROM node:${NODE_VERSION} AS dev

content/guides/reactjs/containerize.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ For consistency, please use the same responses shown in the example below when p
7878
| Question | Answer |
7979
|------------------------------------------------------------|-----------------|
8080
| What application platform does your project use? | Node |
81-
| What version of Node do you want to use? | 22.14.0-alpine |
81+
| What version of Node do you want to use? | 24.7.0-alpine |
8282
| Which package manager do you want to use? | npm |
8383
| Do you want to run "npm run build" before starting server? | yes |
8484
| What directory is your build output to? | dist |
@@ -124,8 +124,8 @@ Copy and replace the contents of your existing `Dockerfile` with the configurati
124124
# =========================================
125125
# Stage 1: Build the React.js Application
126126
# =========================================
127-
ARG NODE_VERSION=22.14.0-alpine
128-
ARG NGINX_VERSION=alpine3.21
127+
ARG NODE_VERSION=24.7.0-alpine
128+
ARG NGINX_VERSION=alpine3.22
129129

130130
# Use a lightweight Node.js image for building (customizable via ARG)
131131
FROM node:${NODE_VERSION} AS builder

content/guides/reactjs/develop.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Create a file named `Dockerfile.dev` in your project root with the following con
3636
# =========================================
3737
# Stage 1: Develop the React.js Application
3838
# =========================================
39-
ARG NODE_VERSION=22.14.0-alpine
39+
ARG NODE_VERSION=24.7.0-alpine
4040

4141
# Use a lightweight Node.js image for development
4242
FROM node:${NODE_VERSION} AS dev

content/guides/vuejs/containerize.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ Replace the contents of your current `Dockerfile` with the optimized configurati
125125
# Stage 1: Build the Vue.js Application
126126
# =========================================
127127
ARG NODE_VERSION=23.11.0-alpine
128-
ARG NGINX_VERSION=alpine3.21
128+
ARG NGINX_VERSION=alpine3.22
129129

130130
# Use a lightweight Node.js image for building (customizable via ARG)
131131
FROM node:${NODE_VERSION} AS builder

0 commit comments

Comments
 (0)