From e1199aac2e2aa9372973325f9e62cd0c5c84cb25 Mon Sep 17 00:00:00 2001 From: Niels V Date: Wed, 17 Jun 2026 15:15:07 +0200 Subject: [PATCH 1/2] bump to node 22 This also switches to bookworm-slim for 3x smaller image. replaced `ps -p` check with equivalent `kill -0` check (ps is not available in slim image) --- Dockerfile | 5 +++-- run-development.sh | 5 ++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index cab2010..2b49271 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,9 @@ -FROM node:20-bookworm +FROM node:22-bookworm-slim LABEL maintainer="team@semantic.works" -RUN apt-get update && apt-get -y upgrade && apt-get -y install git openssh-client rsync jq +RUN apt-get update && apt-get -y upgrade && apt-get -y install --no-install-recommends ca-certificates git openssh-client rsync jq wget \ + && rm -rf /var/lib/apt/lists/* ARG TARGETPLATFORM RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then \ echo "BUILDING FOR AMD64 through $TARGETPLATFORM"; cd /tmp/ && wget https://github.com/watchexec/watchexec/releases/download/v2.3.2/watchexec-2.3.2-x86_64-unknown-linux-gnu.deb && dpkg -i watchexec-2.3.2-x86_64-unknown-linux-gnu.deb; \ diff --git a/run-development.sh b/run-development.sh index 66a4fc7..c938686 100755 --- a/run-development.sh +++ b/run-development.sh @@ -124,9 +124,8 @@ else NODE_PID=$! trap 'kill -s SIGUSR2 $NODE_PID' SIGUSR2 # SIGINT and SIGTERM are not necessary here now - # TODO: Is this ps + while verification step is still necessary? The - # process appeared not to fully exit after `wait`. - while ps -p $NODE_PID > /dev/null + # check if pid is still running + while kill -0 $NODE_PID 2>/dev/null do wait $NODE_PID done From 0b20c5e0b9e3c4b61385fe3a48d7aeaa477bceba Mon Sep 17 00:00:00 2001 From: Niels V Date: Wed, 17 Jun 2026 15:57:12 +0200 Subject: [PATCH 2/2] target Node 22 in babel and tsconfig --- babel.config.json | 2 +- tsconfig-base.json | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/babel.config.json b/babel.config.json index e0192f2..788561e 100644 --- a/babel.config.json +++ b/babel.config.json @@ -3,7 +3,7 @@ ["@babel/preset-env", { "targets": { - "node": 18 + "node": 22 }, "modules": false } diff --git a/tsconfig-base.json b/tsconfig-base.json index 35de81d..9b19ce6 100644 --- a/tsconfig-base.json +++ b/tsconfig-base.json @@ -1,11 +1,11 @@ { "$schema": "https://json.schemastore.org/tsconfig", - "display": "Node 14", + "display": "Node 22", "compilerOptions": { - "lib": ["es2020"], - "module": "es2020", - "target": "es2020", + "lib": ["es2022"], + "module": "es2022", + "target": "es2022", "allowJs": true, "noEmit": true,