This is an automated email from the ASF dual-hosted git repository.
jason810496 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 36005d772dd Bake Node.js and pnpm runtime into breeze CI image (#70285)
36005d772dd is described below
commit 36005d772dd629c862223523b7c32adf5ba3db52
Author: Jason(Zhe-You) Liu <[email protected]>
AuthorDate: Fri Jul 24 11:50:02 2026 +0800
Bake Node.js and pnpm runtime into breeze CI image (#70285)
---
Dockerfile | 33 +++++++++++++++++++++++++++++
Dockerfile.ci | 35 +++++++++++++++++++++++++++++++
scripts/docker/install_os_dependencies.sh | 35 +++++++++++++++++++++++++++++++
3 files changed, 103 insertions(+)
diff --git a/Dockerfile b/Dockerfile
index 2aadb987808..ef2a70177d9 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -123,6 +123,8 @@ AIRFLOW_PYTHON_VERSION=${AIRFLOW_PYTHON_VERSION:-3.10.18}
PYTHON_LTO=${PYTHON_LTO:-true}
GOLANG_MAJOR_MINOR_VERSION=${GOLANG_MAJOR_MINOR_VERSION:-1.24.4}
TEMURIN_VERSION=${TEMURIN_VERSION:-11}
+NODEJS_VERSION=${NODEJS_VERSION:-22.23.1}
+PNPM_VERSION=${PNPM_VERSION:-10.28.1}
RUSTUP_DEFAULT_TOOLCHAIN=${RUSTUP_DEFAULT_TOOLCHAIN:-stable}
RUSTUP_VERSION=${RUSTUP_VERSION:-1.29.0}
COSIGN_VERSION=${COSIGN_VERSION:-3.0.5}
@@ -514,6 +516,36 @@ https://packages.adoptium.net/artifactory/deb
${DISTRO_CODENAME} main" \
rm -rf /var/lib/apt/lists/*
}
+function install_nodejs() {
+ local arch
+ arch="$(dpkg --print-architecture)"
+ declare -A nodejs_targets=(
+ [amd64]="linux-x64"
+ [arm64]="linux-arm64"
+ )
+ declare -A nodejs_sha256s=(
+ # https://nodejs.org/dist/v${NODEJS_VERSION}/SHASUMS256.txt
+
[amd64]="9749e988f437343b7fa832c69ded82a312e41a03116d766797ac14f6f9eee578"
+
[arm64]="0294e8b915ab75f92c7513d2fcb830ae06e10684e6c603e99a87dbf8835389c1"
+ )
+ local target="${nodejs_targets[${arch}]}"
+ local nodejs_sha256="${nodejs_sha256s[${arch}]}"
+ if [[ -z "${target}" ]]; then
+ echo "Unsupported architecture for nodejs: ${arch}"
+ exit 1
+ fi
+ curl --retry 3 --retry-delay 5 \
+
"https://nodejs.org/dist/v${NODEJS_VERSION}/node-v${NODEJS_VERSION}-${target}.tar.xz"
\
+ -o /tmp/nodejs.tar.xz
+ echo "${nodejs_sha256} /tmp/nodejs.tar.xz" | sha256sum --check
+ tar -xJf /tmp/nodejs.tar.xz --strip-components=1 -C /usr/local
--no-same-owner
+ rm -f /tmp/nodejs.tar.xz
+ corepack enable --install-directory /usr/local/bin
+ # corepack enable only writes shims; prepare downloads and caches the pnpm
binary into the
+ # image so it is available offline and matches the version ts-sdk pins.
+ corepack prepare "pnpm@${PNPM_VERSION}" --activate
+}
+
function install_rustup() {
local arch
arch="$(dpkg --print-architecture)"
@@ -560,6 +592,7 @@ else
if [[ "${INSTALLATION_TYPE}" == "CI" ]]; then
install_golang
install_jdk
+ install_nodejs
fi
install_docker_cli
apt_clean
diff --git a/Dockerfile.ci b/Dockerfile.ci
index 9ed2220d7d6..72484d78588 100644
--- a/Dockerfile.ci
+++ b/Dockerfile.ci
@@ -63,6 +63,8 @@ AIRFLOW_PYTHON_VERSION=${AIRFLOW_PYTHON_VERSION:-3.10.18}
PYTHON_LTO=${PYTHON_LTO:-true}
GOLANG_MAJOR_MINOR_VERSION=${GOLANG_MAJOR_MINOR_VERSION:-1.24.4}
TEMURIN_VERSION=${TEMURIN_VERSION:-11}
+NODEJS_VERSION=${NODEJS_VERSION:-22.23.1}
+PNPM_VERSION=${PNPM_VERSION:-10.28.1}
RUSTUP_DEFAULT_TOOLCHAIN=${RUSTUP_DEFAULT_TOOLCHAIN:-stable}
RUSTUP_VERSION=${RUSTUP_VERSION:-1.29.0}
COSIGN_VERSION=${COSIGN_VERSION:-3.0.5}
@@ -454,6 +456,36 @@ https://packages.adoptium.net/artifactory/deb
${DISTRO_CODENAME} main" \
rm -rf /var/lib/apt/lists/*
}
+function install_nodejs() {
+ local arch
+ arch="$(dpkg --print-architecture)"
+ declare -A nodejs_targets=(
+ [amd64]="linux-x64"
+ [arm64]="linux-arm64"
+ )
+ declare -A nodejs_sha256s=(
+ # https://nodejs.org/dist/v${NODEJS_VERSION}/SHASUMS256.txt
+
[amd64]="9749e988f437343b7fa832c69ded82a312e41a03116d766797ac14f6f9eee578"
+
[arm64]="0294e8b915ab75f92c7513d2fcb830ae06e10684e6c603e99a87dbf8835389c1"
+ )
+ local target="${nodejs_targets[${arch}]}"
+ local nodejs_sha256="${nodejs_sha256s[${arch}]}"
+ if [[ -z "${target}" ]]; then
+ echo "Unsupported architecture for nodejs: ${arch}"
+ exit 1
+ fi
+ curl --retry 3 --retry-delay 5 \
+
"https://nodejs.org/dist/v${NODEJS_VERSION}/node-v${NODEJS_VERSION}-${target}.tar.xz"
\
+ -o /tmp/nodejs.tar.xz
+ echo "${nodejs_sha256} /tmp/nodejs.tar.xz" | sha256sum --check
+ tar -xJf /tmp/nodejs.tar.xz --strip-components=1 -C /usr/local
--no-same-owner
+ rm -f /tmp/nodejs.tar.xz
+ corepack enable --install-directory /usr/local/bin
+ # corepack enable only writes shims; prepare downloads and caches the pnpm
binary into the
+ # image so it is available offline and matches the version ts-sdk pins.
+ corepack prepare "pnpm@${PNPM_VERSION}" --activate
+}
+
function install_rustup() {
local arch
arch="$(dpkg --print-architecture)"
@@ -500,6 +532,7 @@ else
if [[ "${INSTALLATION_TYPE}" == "CI" ]]; then
install_golang
install_jdk
+ install_nodejs
fi
install_docker_cli
apt_clean
@@ -1722,6 +1755,8 @@ ARG AIRFLOW_PYTHON_VERSION="3.13.14"
ENV AIRFLOW_PYTHON_VERSION=${AIRFLOW_PYTHON_VERSION}
ENV GOLANG_MAJOR_MINOR_VERSION="1.26.5"
ENV TEMURIN_VERSION="11"
+ENV NODEJS_VERSION="22.23.1"
+ENV PNPM_VERSION="10.28.1"
ENV RUSTUP_HOME="/usr/local/rustup"
ENV CARGO_HOME="/usr/local/cargo"
ENV PATH="${CARGO_HOME}/bin:${PATH}"
diff --git a/scripts/docker/install_os_dependencies.sh
b/scripts/docker/install_os_dependencies.sh
index e5a540c525c..4ce256bc5db 100644
--- a/scripts/docker/install_os_dependencies.sh
+++ b/scripts/docker/install_os_dependencies.sh
@@ -29,6 +29,10 @@ AIRFLOW_PYTHON_VERSION=${AIRFLOW_PYTHON_VERSION:-3.10.18}
PYTHON_LTO=${PYTHON_LTO:-true}
GOLANG_MAJOR_MINOR_VERSION=${GOLANG_MAJOR_MINOR_VERSION:-1.24.4}
TEMURIN_VERSION=${TEMURIN_VERSION:-11}
+NODEJS_VERSION=${NODEJS_VERSION:-22.23.1}
+# Keep in sync with the "packageManager" pin in ts-sdk/package.json so the
version corepack
+# resolves for ts-sdk is the one baked into the image.
+PNPM_VERSION=${PNPM_VERSION:-10.28.1}
RUSTUP_DEFAULT_TOOLCHAIN=${RUSTUP_DEFAULT_TOOLCHAIN:-stable}
RUSTUP_VERSION=${RUSTUP_VERSION:-1.29.0}
COSIGN_VERSION=${COSIGN_VERSION:-3.0.5}
@@ -420,6 +424,36 @@ https://packages.adoptium.net/artifactory/deb
${DISTRO_CODENAME} main" \
rm -rf /var/lib/apt/lists/*
}
+function install_nodejs() {
+ local arch
+ arch="$(dpkg --print-architecture)"
+ declare -A nodejs_targets=(
+ [amd64]="linux-x64"
+ [arm64]="linux-arm64"
+ )
+ declare -A nodejs_sha256s=(
+ # https://nodejs.org/dist/v${NODEJS_VERSION}/SHASUMS256.txt
+
[amd64]="9749e988f437343b7fa832c69ded82a312e41a03116d766797ac14f6f9eee578"
+
[arm64]="0294e8b915ab75f92c7513d2fcb830ae06e10684e6c603e99a87dbf8835389c1"
+ )
+ local target="${nodejs_targets[${arch}]}"
+ local nodejs_sha256="${nodejs_sha256s[${arch}]}"
+ if [[ -z "${target}" ]]; then
+ echo "Unsupported architecture for nodejs: ${arch}"
+ exit 1
+ fi
+ curl --retry 3 --retry-delay 5 \
+
"https://nodejs.org/dist/v${NODEJS_VERSION}/node-v${NODEJS_VERSION}-${target}.tar.xz"
\
+ -o /tmp/nodejs.tar.xz
+ echo "${nodejs_sha256} /tmp/nodejs.tar.xz" | sha256sum --check
+ tar -xJf /tmp/nodejs.tar.xz --strip-components=1 -C /usr/local
--no-same-owner
+ rm -f /tmp/nodejs.tar.xz
+ corepack enable --install-directory /usr/local/bin
+ # corepack enable only writes shims; prepare downloads and caches the pnpm
binary into the
+ # image so it is available offline and matches the version ts-sdk pins.
+ corepack prepare "pnpm@${PNPM_VERSION}" --activate
+}
+
function install_rustup() {
local arch
arch="$(dpkg --print-architecture)"
@@ -466,6 +500,7 @@ else
if [[ "${INSTALLATION_TYPE}" == "CI" ]]; then
install_golang
install_jdk
+ install_nodejs
fi
install_docker_cli
apt_clean