Skip to content

Commit f4b0fee

Browse files
Support: javascript-node 24 (devcontainers#1423)
* Support: javascript-node 24 and typescript-node 24 ## Summary Add Node.js 24 support to JavaScript and TypeScript devcontainer images and update defaults and documentation accordingly. New Features: - Add support for Node.js 24 variants (24-bookworm and 24-bullseye) in both javascript-node and typescript-node images Enhancements: - Set the default 'latest' variant and devcontainer ARG to 24-bookworm Build: - Update manifest.json files to include new 24 variants with architectures and variantTags Documentation: - Update README files to list and reference the new 24 image tags and adjust security patching examples * Update reference node image version * build: remove typescript changes * Fix typo * chore: version up manifest.json --------- Co-authored-by: Álvaro Rausell Guiard <33221237+AlvaroRausell@users.noreply.github.com>
1 parent aa6ce63 commit f4b0fee

File tree

4 files changed

+45
-11
lines changed

4 files changed

+45
-11
lines changed

cgmanifest.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -605,6 +605,16 @@
605605
}
606606
}
607607
},
608+
{
609+
"Component": {
610+
"Type": "other",
611+
"Other": {
612+
"Name": "Docker Image: node",
613+
"Version": "24-bookworm",
614+
"DownloadUrl": "https://hub.docker.com/_/node"
615+
}
616+
}
617+
},
608618
{
609619
"Component": {
610620
"Type": "other",
@@ -635,6 +645,16 @@
635645
}
636646
}
637647
},
648+
{
649+
"Component": {
650+
"Type": "other",
651+
"Other": {
652+
"Name": "Docker Image: node",
653+
"Version": "24-bullseye",
654+
"DownloadUrl": "https://hub.docker.com/_/node"
655+
}
656+
}
657+
},
638658
{
639659
"Component": {
640660
"Type": "other",

src/javascript-node/.devcontainer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG VARIANT=22-bookworm
1+
ARG VARIANT=24-bookworm
22
FROM node:${VARIANT}
33

44
ARG USERNAME=node

src/javascript-node/README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
| *Categories* | Core, Languages |
1010
| *Image type* | Dockerfile |
1111
| *Published image* | mcr.microsoft.com/devcontainers/javascript-node |
12-
| *Available image variants* | 22 / 22-bookworm, 20 / 20-bookworm, 20-bullseye, ([full list](https://mcr.microsoft.com/v2/devcontainers/javascript-node/tags/list)) |
12+
| *Available image variants* | 24 / 24-bookworm, 22 / 22-bookworm, 20 / 20-bookworm, 24-bullseye, 22-bullseye, 20-bullseye, ([full list](https://mcr.microsoft.com/v2/devcontainers/javascript-node/tags/list)) |
1313
| *Published image architecture(s)* | x86-64, arm64/aarch64 for `bookworm`, and `bullseye` variants |
1414
| *Container host OS support* | Linux, macOS, Windows |
1515
| *Container OS* | Debian |
@@ -20,18 +20,19 @@
2020
You can directly reference pre-built versions of `Dockerfile` by using the `image` property in `.devcontainer/devcontainer.json` or updating the `FROM` statement in your own `Dockerfile` to one of the following. An example `Dockerfile` is included in this repository.
2121

2222
- `mcr.microsoft.com/devcontainers/javascript-node` (latest)
23+
- `mcr.microsoft.com/devcontainers/javascript-node:24` (or `24-bookworm`, `24-bullseye` to pin to an OS version)
2324
- `mcr.microsoft.com/devcontainers/javascript-node:22` (or `22-bookworm`, `22-bullseye` to pin to an OS version)
2425
- `mcr.microsoft.com/devcontainers/javascript-node:20` (or `20-bookworm`, `20-bullseye` to pin to an OS version)
2526

2627
Refer to [this guide](https://containers.dev/guide/dockerfile) for more details.
2728

2829
You can decide how often you want updates by referencing a [semantic version](https://semver.org/) of each image. For example:
2930

30-
- `mcr.microsoft.com/devcontainers/typescript-node:2-22` (or `2-22-bookworm`, `2-22-bullseye`)
31-
- `mcr.microsoft.com/devcontainers/typescript-node:2.0-22` (or `2.0-22-bookworm`, `2.0-22-bullseye`)
32-
- `mcr.microsoft.com/devcontainers/typescript-node:2.0.0-22` (or `2.0.0-22-bookworm`, `2.0.0-22-bullseye`)
31+
- `mcr.microsoft.com/devcontainers/javascript-node:2-24` (or `2-24-bookworm`, `2-24-bullseye`)
32+
- `mcr.microsoft.com/devcontainers/javascript-node:2.0-24` (or `2.0-24-bookworm`, `2.0-24-bullseye`)
33+
- `mcr.microsoft.com/devcontainers/javascript-node:2.0.0-24` (or `2.0.0-24-bookworm`, `2.0.0-24-bullseye`)
3334

34-
However, we only do security patching on the latest [non-breaking, in support](https://github.com/devcontainers/images/issues/90) versions of images (e.g. `1-1.0`). You may want to run `apt-get update && apt-get upgrade` in your Dockerfile if you lock to a more specific version to at least pick up OS security updates.
35+
However, we only do security patching on the latest [non-breaking, in support](https://github.com/devcontainers/images/issues/90) versions of images (e.g. `2-24`). You may want to run `apt-get update && apt-get upgrade` in your Dockerfile if you lock to a more specific version to at least pick up OS security updates.
3536

3637
Beyond Node.js and `git`, this image / `Dockerfile` includes `eslint`, `zsh`, [Oh My Zsh!](https://ohmyz.sh/), a non-root `node` user with `sudo` access, and a set of common dependencies for development. [Node Version Manager](https://github.com/nvm-sh/nvm) (`nvm`) is also included in case you need to use a different version of Node.js than the one included in the image.
3738

src/javascript-node/manifest.json

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,21 @@
11
{
2-
"version": "2.0.0",
2+
"version": "3.0.0",
33
"variants": [
4+
"24-bookworm",
45
"22-bookworm",
56
"20-bookworm",
7+
"24-bullseye",
68
"22-bullseye",
79
"20-bullseye"
810
],
911
"build": {
10-
"latest": "22-bookworm",
12+
"latest": "24-bookworm",
1113
"rootDistro": "debian",
1214
"architectures": {
15+
"24-bookworm": [
16+
"linux/amd64",
17+
"linux/arm64"
18+
],
1319
"22-bookworm": [
1420
"linux/amd64",
1521
"linux/arm64"
@@ -18,6 +24,10 @@
1824
"linux/amd64",
1925
"linux/arm64"
2026
],
27+
"24-bullseye": [
28+
"linux/amd64",
29+
"linux/arm64"
30+
],
2131
"22-bullseye": [
2232
"linux/amd64",
2333
"linux/arm64"
@@ -31,14 +41,17 @@
3141
"javascript-node:${VERSION}-${VARIANT}"
3242
],
3343
"variantTags": {
34-
"22-bookworm": [
35-
"javascript-node:${VERSION}-22",
44+
"24-bookworm": [
45+
"javascript-node:${VERSION}-24",
3646
"javascript-node:${VERSION}-bookworm"
3747
],
48+
"22-bookworm": [
49+
"javascript-node:${VERSION}-22"
50+
],
3851
"20-bookworm": [
3952
"javascript-node:${VERSION}-20"
4053
],
41-
"22-bullseye": [
54+
"24-bullseye": [
4255
"javascript-node:${VERSION}-bullseye"
4356
]
4457
}

0 commit comments

Comments
 (0)