From 16146ed6dc81b1076402a737c25e95c59f9d5f8f Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 1 Sep 2021 22:37:42 +0000 Subject: [PATCH] Add Javascript / Typescript arm64 images --- .../javascript-node/.devcontainer/Dockerfile | 4 ++-- .../.devcontainer/base.Dockerfile | 4 ++-- .../.devcontainer/devcontainer.json | 5 ++-- containers/javascript-node/README.md | 23 +++++++++++-------- .../javascript-node/definition-manifest.json | 20 +++++++++++----- .../typescript-node/.devcontainer/Dockerfile | 4 ++-- .../.devcontainer/base.Dockerfile | 4 ++-- .../.devcontainer/devcontainer.json | 5 ++-- containers/typescript-node/README.md | 23 +++++++++++-------- .../typescript-node/definition-manifest.json | 12 ++++++++-- 10 files changed, 64 insertions(+), 40 deletions(-) diff --git a/containers/javascript-node/.devcontainer/Dockerfile b/containers/javascript-node/.devcontainer/Dockerfile index c0b0f1d787..ea0f31c66a 100644 --- a/containers/javascript-node/.devcontainer/Dockerfile +++ b/containers/javascript-node/.devcontainer/Dockerfile @@ -1,5 +1,5 @@ -# [Choice] Node.js version: 16, 14, 12 -ARG VARIANT=16 +# [Choice] Node.js version: 16, 14, 12, 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster +ARG VARIANT=16-bullseye FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:${VARIANT} # [Optional] Uncomment this section to install additional OS packages. diff --git a/containers/javascript-node/.devcontainer/base.Dockerfile b/containers/javascript-node/.devcontainer/base.Dockerfile index 5634f29081..29e50ae920 100644 --- a/containers/javascript-node/.devcontainer/base.Dockerfile +++ b/containers/javascript-node/.devcontainer/base.Dockerfile @@ -1,5 +1,5 @@ -# [Choice] Node.js version: 16, 14, 12 -ARG VARIANT=16-buster +# [Choice] Node.js version: 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster +ARG VARIANT=16-bullseye FROM node:${VARIANT} # [Option] Install zsh diff --git a/containers/javascript-node/.devcontainer/devcontainer.json b/containers/javascript-node/.devcontainer/devcontainer.json index 1adbaf0c90..69bba603cc 100644 --- a/containers/javascript-node/.devcontainer/devcontainer.json +++ b/containers/javascript-node/.devcontainer/devcontainer.json @@ -2,8 +2,9 @@ "name": "Node.js", "build": { "dockerfile": "Dockerfile", - // Update 'VARIANT' to pick a Node version: 12, 14, 16 - "args": { "VARIANT": "16" } + // Update 'VARIANT' to pick a Node version: 16, 14, 12. + // Append -bullseye or -buster to pin to an OS version. + "args": { "VARIANT": "16-bullseye" } }, // Set *default* container specific settings.json values on container create. diff --git a/containers/javascript-node/README.md b/containers/javascript-node/README.md index 1aaf278e1c..bdaf91f1df 100644 --- a/containers/javascript-node/README.md +++ b/containers/javascript-node/README.md @@ -10,8 +10,8 @@ | *Categories* | Core, Languages | | *Definition type* | Dockerfile | | *Published image* | mcr.microsoft.com/vscode/devcontainers/javascript-node | -| *Available image variants* | 12, 14, 16 ([full list](https://mcr.microsoft.com/v2/vscode/devcontainers/javascript-node/tags/list)) | -| *Published image architecture(s)* | x86-64 | +| *Available image variants* | 12 / 12-bullseye, 14 / 14-bullseye, 16 / 16-bullseye, 12-buster, 14-buster, 16-buster ([full list](https://mcr.microsoft.com/v2/vscode/devcontainers/javascript-node/tags/list)) | +| *Published image architecture(s)* | x86-64, arm64/aarch64 for `bullseye` variants | | *Works in Codespaces* | Yes | | *Container host OS support* | Linux, macOS, Windows | | *Container OS* | Debian | @@ -23,22 +23,25 @@ See **[history](history)** for information on the contents of published images. While the definition itself works unmodified, you can select the version of Node.js the container uses by updating the `VARIANT` arg in the included `devcontainer.json` (and rebuilding if you've already created the container). -```json -"args": { "VARIANT": "12" } +```jsonc +// Or you can use 14-bullseye if you want to pin to an OS version +"args": { "VARIANT": "14" } ``` You can also directly reference pre-built versions of `.devcontainer/base.Dockerfile` by using the `image` property in `.devcontainer/devcontainer.json` or updating the `FROM` statement in your own `Dockerfile` with one of the following: - `mcr.microsoft.com/vscode/devcontainers/javascript-node` (latest) -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:16` -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:14` -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:12` +- `mcr.microsoft.com/vscode/devcontainers/javascript-node:16` (or `16-bullseye` to stay on this OS version) +- `mcr.microsoft.com/vscode/devcontainers/javascript-node:14` (or `14-bullseye` to stay on this OS version) +- `mcr.microsoft.com/vscode/devcontainers/javascript-node:12` (or `12-bullseye` to stay on this OS version) You can decide how often you want updates by referencing a [semantic version](https://semver.org/) of each image. For example: -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:0-12` -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:0.202-12` -- `mcr.microsoft.com/vscode/devcontainers/javascript-node:0.202.1-12` +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0-14` (or `0-14-bullseye`) +- `mcr.microsoft.com/vscode/devcontainers/javascript-node:0.204-14` (or `0.203-14-bullseye`) +- `mcr.microsoft.com/vscode/devcontainers/javascript-node:0.204.0-14` (or `0.203.0-14-bullseye`) + +However, we only do security patching on the latest [non-breaking, in support](https://github.com/microsoft/vscode-dev-containers/issues/532) versions of images (e.g. `0-14`). 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. See [history](history) for information on the contents of each version and [here for a complete list of available tags](https://mcr.microsoft.com/v2/vscode/devcontainers/typescript-node/tags/list). diff --git a/containers/javascript-node/definition-manifest.json b/containers/javascript-node/definition-manifest.json index 21eb6700d6..4fc10a6c95 100644 --- a/containers/javascript-node/definition-manifest.json +++ b/containers/javascript-node/definition-manifest.json @@ -1,16 +1,24 @@ { - "variants": ["16-buster", "14-buster", "12-buster", "14-stretch", "12-stretch"], - "definitionVersion": "0.202.7", + "variants": ["16-bullseye", "14-bullseye", "12-bullseye", "16-buster", "14-buster", "12-buster"], + "definitionVersion": "0.203.0", "build": { - "latest": true, + "latest": "16-bullseye", "rootDistro": "debian", + "architectures": { + "16-bullseye": ["linux/amd64", "linux/arm64"], + "14-bullseye": ["linux/amd64", "linux/arm64"], + "12-bullseye": ["linux/amd64", "linux/arm64"], + "16-buster": ["linux/amd64"], + "14-buster": ["linux/amd64"], + "12-buster": ["linux/amd64"] + }, "tags": [ "javascript-node:${VERSION}-${VARIANT}" ], "variantTags": { - "16-buster": [ "javascript-node:${VERSION}-16" ], - "14-buster": [ "javascript-node:${VERSION}-14" ], - "12-buster": [ "javascript-node:${VERSION}-12" ] + "16-bullseye": [ "javascript-node:${VERSION}-16" ], + "14-bullseye": [ "javascript-node:${VERSION}-14" ], + "12-bullseye": [ "javascript-node:${VERSION}-12" ] } }, "dependencies": { diff --git a/containers/typescript-node/.devcontainer/Dockerfile b/containers/typescript-node/.devcontainer/Dockerfile index 5d6b5b9411..0231f96215 100644 --- a/containers/typescript-node/.devcontainer/Dockerfile +++ b/containers/typescript-node/.devcontainer/Dockerfile @@ -1,5 +1,5 @@ -# [Choice] Node.js version: 16, 14, 12 -ARG VARIANT=16 +# [Choice] Node.js version: 16, 14, 12, 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster +ARG VARIANT=16-bullseye FROM mcr.microsoft.com/vscode/devcontainers/typescript-node:${VARIANT} # [Optional] Uncomment this section to install additional OS packages. diff --git a/containers/typescript-node/.devcontainer/base.Dockerfile b/containers/typescript-node/.devcontainer/base.Dockerfile index 1d71af3d92..33cbe1f8e0 100644 --- a/containers/typescript-node/.devcontainer/base.Dockerfile +++ b/containers/typescript-node/.devcontainer/base.Dockerfile @@ -1,5 +1,5 @@ -# [Choice] Node.js version: 16, 14, 12 -ARG VARIANT=16-buster +# [Choice] Node.js version: 16, 14, 12, 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster +ARG VARIANT=16-bullseye FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT} # Install tslint, typescript. eslint is installed by javascript image diff --git a/containers/typescript-node/.devcontainer/devcontainer.json b/containers/typescript-node/.devcontainer/devcontainer.json index 00b1dff755..2fa7303653 100644 --- a/containers/typescript-node/.devcontainer/devcontainer.json +++ b/containers/typescript-node/.devcontainer/devcontainer.json @@ -2,9 +2,10 @@ "name": "Node.js & TypeScript", "build": { "dockerfile": "Dockerfile", - // Update 'VARIANT' to pick a Node version: 12, 14, 16 + // Update 'VARIANT' to pick a Node version: 16, 14, 12. + // Append -bullseye or -buster to pin to an OS version. "args": { - "VARIANT": "16" + "VARIANT": "16-bullseye" } }, diff --git a/containers/typescript-node/README.md b/containers/typescript-node/README.md index 0882bad4f1..79dc1c8c6d 100644 --- a/containers/typescript-node/README.md +++ b/containers/typescript-node/README.md @@ -10,8 +10,8 @@ | *Categories* | Core, Languages | | *Definition type* | Dockerfile | | *Published image* | mcr.microsoft.com/vscode/devcontainers/typescript-node | -| *Available image variants* | 12, 14, 16 ([full list](https://mcr.microsoft.com/v2/vscode/devcontainers/typescript-node/tags/list)) | -| *Published image architecture(s)* | x86-64 | +| *Available image variants* | 12 / 12-bullseye, 14 / 14-bullseye, 16 / 16-bullseye, 12-buster, 14-buster, 16-buster ([full list](https://mcr.microsoft.com/v2/vscode/devcontainers/javascript-node/tags/list)) | +| *Published image architecture(s)* | x86-64, arm64/aarch64 for `bullseye` variants | | *Works in Codespaces* | Yes | | *Container host OS support* | Linux, macOS, Windows | | *Container OS* | Debian | @@ -23,22 +23,25 @@ See **[history](history)** for information on the contents of published images. While the definition itself works unmodified, you can select the version of Node.js the container uses by updating the `VARIANT` arg in the included `devcontainer.json` (and rebuilding if you've already created the container). -```json -"args": { "VARIANT": "12" } +```jsonc +// Or you can use 14-bullseye if you want to pin to an OS version +"args": { "VARIANT": "14" } ``` You can also directly reference pre-built versions of `.devcontainer/base.Dockerfile` by using the `image` property in `.devcontainer/devcontainer.json` or updating the `FROM` statement in your own `Dockerfile` with one of the following: - `mcr.microsoft.com/vscode/devcontainers/typescript-node` (latest) -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:16` -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:14` -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:12` +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:16` (or `16-bullseye` to stay on this OS version) +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:14` (or `14-bullseye` to stay on this OS version) +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:12` (or `12-bullseye` to stay on this OS version) You can decide how often you want updates by referencing a [semantic version](https://semver.org/) of each image. For example: -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0-12` -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0.202-12` -- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0.202.1-12` +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0-14` (or `0-14-bullseye`) +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0.204-14` (or `0.203-14-bullseye`) +- `mcr.microsoft.com/vscode/devcontainers/typescript-node:0.204.0-14` (or `0.203.0-14-bullseye`) + +However, we only do security patching on the latest [non-breaking, in support](https://github.com/microsoft/vscode-dev-containers/issues/532) versions of images (e.g. `0-14`). 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. See [history](history) for information on the contents of each version and [here for a complete list of available tags](https://mcr.microsoft.com/v2/vscode/devcontainers/typescript-node/tags/list). diff --git a/containers/typescript-node/definition-manifest.json b/containers/typescript-node/definition-manifest.json index 08a3de4140..a2370e5479 100644 --- a/containers/typescript-node/definition-manifest.json +++ b/containers/typescript-node/definition-manifest.json @@ -1,10 +1,18 @@ { - "variants": ["16-buster", "14-buster", "12-buster", "14-stretch", "12-stretch"], - "definitionVersion": "0.202.7", + "variants": ["16-bullseye", "14-bullseye", "12-bullseye", "16-buster", "14-buster", "12-buster"], + "definitionVersion": "0.203.0", "build": { "latest": true, "rootDistro": "debian", "parent": "javascript-node", + "architectures": { + "16-bullseye": ["linux/amd64", "linux/arm64"], + "14-bullseye": ["linux/amd64", "linux/arm64"], + "12-bullseye": ["linux/amd64", "linux/arm64"], + "16-buster": ["linux/amd64"], + "14-buster": ["linux/amd64"], + "12-buster": ["linux/amd64"] + }, "tags": [ "typescript-node:${VERSION}-${VARIANT}" ],