From 94936315840d08981a461a9bb6307ded87c23b99 Mon Sep 17 00:00:00 2001 From: Charlie Kolb Date: Wed, 5 Aug 2026 14:26:16 +0200 Subject: [PATCH] feat: Add task-runners sidecar to the get.n8n.io stack (#35426) Co-authored-by: Claude Fable 5 --- docker/get-n8n.sh | 18 ++++++++++++++++++ docker/test-get-n8n.sh | 1 + 2 files changed, 19 insertions(+) diff --git a/docker/get-n8n.sh b/docker/get-n8n.sh index fb7ccb4a061..140f3deb1ec 100755 --- a/docker/get-n8n.sh +++ b/docker/get-n8n.sh @@ -187,6 +187,13 @@ N8N_VERSION=${INSTALL_VERSION} N8N_ENABLED_MODULES=instance-ai +# Code-node user code (JavaScript and Python) runs in the separate 'runners' +# container. The broker binds 0.0.0.0 so that container can reach it — its +# port (5679) stays private to the compose network. +N8N_RUNNERS_MODE=external +N8N_RUNNERS_BROKER_LISTEN_ADDRESS=0.0.0.0 +N8N_RUNNERS_AUTH_TOKEN=$(gen_secret) + # Instance AI (optional): fill this in to enable the AI assistant in n8n. # n8n works fine without it. Setup guide: # https://docs.n8n.io/deploy/host-n8n/configure-n8n/set-up-ai-assistant @@ -304,6 +311,17 @@ services: volumes: - n8n-data:/home/node/.n8n + runners: + image: ghcr.io/n8n-io/runners:${N8N_VERSION} + depends_on: + - n8n + environment: + N8N_RUNNERS_AUTH_TOKEN: ${N8N_RUNNERS_AUTH_TOKEN} + N8N_RUNNERS_TASK_BROKER_URI: http://n8n:5679 + # Idle runners exit and are relaunched on demand (per the task-runners docs) + N8N_RUNNERS_AUTO_SHUTDOWN_TIMEOUT: '15' + # Runs user code from Code nodes. Never publish this container's ports. + searxng: image: ghcr.io/searxng/searxng:latest environment: diff --git a/docker/test-get-n8n.sh b/docker/test-get-n8n.sh index e46ffb5e458..894b76f738e 100644 --- a/docker/test-get-n8n.sh +++ b/docker/test-get-n8n.sh @@ -182,6 +182,7 @@ if [ "$E2E" -eq 1 ]; then echo "$ps_out" | grep -q '^sandbox-runner-1 running' && pass "sandbox-runner running" || fail "sandbox-runner running" echo "$ps_out" | grep -q '^n8n running' && pass "n8n running" || fail "n8n running" echo "$ps_out" | grep -q '^searxng running' && pass "searxng running" || fail "searxng running" + echo "$ps_out" | grep -q '^runners running' && pass "task runners running" || fail "task runners running" check "n8n reaches sandbox-api" \ docker compose -f "$E2E_DIR/compose.yml" exec -T n8n wget -qO- http://sandbox-api:8080/healthz