Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
fd7745f
ci: Change e2e to pull prebuilt docker image
shortstacked Dec 12, 2025
2da4b46
Merge remote-tracking branch 'origin/master' into cat-1920-ci-find-a-…
shortstacked Dec 12, 2025
11f7e0c
ci: Consolidate composite actions
shortstacked Dec 12, 2025
1a25f06
ci: Small tweaks
shortstacked Dec 13, 2025
3444b7e
ci: Final cleanup
shortstacked Dec 13, 2025
6e38310
Merge branch 'master' into CAT-1920
shortstacked Dec 13, 2025
558003b
ci: Improve cancelling in progress
shortstacked Dec 13, 2025
98f0901
Merge branch 'master' into CAT-1920
shortstacked Dec 15, 2025
09f06ef
Merge branch 'master' into CAT-1920
shortstacked Dec 15, 2025
e4a7ac1
ci: Cleanup of Playwright turbo tasks
shortstacked Dec 15, 2025
b13c892
ci: Go back to local build mode
shortstacked Dec 15, 2025
fefaedc
ci: Change e2e to pull prebuilt docker image
shortstacked Dec 12, 2025
a444bef
ci: Consolidate composite actions
shortstacked Dec 12, 2025
7c79e10
ci: Small tweaks
shortstacked Dec 13, 2025
0938262
ci: Final cleanup
shortstacked Dec 13, 2025
6a0ff9e
ci: Improve cancelling in progress
shortstacked Dec 13, 2025
c3a40af
ci: Cleanup of Playwright turbo tasks
shortstacked Dec 15, 2025
ce9e449
ci: Go back to local build mode
shortstacked Dec 15, 2025
ed33ac6
ci: Optional skip licenses
shortstacked Dec 15, 2025
55db1d9
Merge remote-tracking branch 'origin/CAT-1920' into cat-1920-ci-find-…
shortstacked Dec 15, 2025
85777ff
Merge branch 'master' into CAT-1920
shortstacked Dec 15, 2025
854dc1f
ci: Fix cache inconsistency
shortstacked Dec 15, 2025
dc4d4d3
Merge branch 'master' into CAT-1920
shortstacked Dec 15, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 0 additions & 33 deletions .github/actions/setup-nodejs-github/action.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
name: 'Blacksmith Node.js Build Setup'
# This action works transparently on both Blacksmith and GitHub-hosted runners.
# Blacksmith runners benefit from transparent caching and optional Docker layer caching.
# GitHub-hosted runners use standard GitHub Actions caching.

name: 'Node.js Build Setup'
description: 'Configures Node.js with pnpm, installs dependencies, enables Turborepo caching, (optional) sets up Docker layer caching, and builds the project or an optional command.'

inputs:
Expand All @@ -7,7 +11,7 @@ inputs:
required: false
default: '22.x'
enable-docker-cache:
description: 'Whether to set up Blacksmith Buildx for Docker layer caching.'
description: 'Whether to set up Blacksmith Buildx for Docker layer caching (Blacksmith runners only).'
required: false
default: 'false'
type: boolean
Expand All @@ -20,22 +24,25 @@ inputs:
runs:
using: 'composite'
steps:
- name: Setup pnpm
uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0

- name: Setup Node.js
uses: useblacksmith/setup-node@65c6ca86fdeb0ab3d85e78f57e4f6a7e4780b391 # v5.0.4
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
with:
node-version: ${{ inputs.node-version }}
cache: 'pnpm'

- name: Setup pnpm and Install Dependencies
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
with:
run_install: true
- name: Install Dependencies
run: pnpm install --frozen-lockfile
shell: bash

- name: Configure Turborepo Cache
uses: useblacksmith/caching-for-turbo@bafb57e7ebdbf1185762286ec94d24648cd3938a # v1
uses: rharkor/caching-for-turbo@cda201ff2b32699a2ae9f59704db029e3dde4fbd # v2.3.5

- name: Setup Docker Builder for Docker Cache
if: ${{ inputs.enable-docker-cache == 'true' }}
uses: useblacksmith/setup-docker-builder@0b434dfbb431f4e3a2bcee7a773a56bd363184c5 # v1
uses: useblacksmith/setup-docker-builder@53647ab5afe8827af5623b35bd4302eabd41619f # v1.2.0

- name: Build Project
run: ${{ inputs.build-command }}
Expand Down
2 changes: 1 addition & 1 deletion .github/scripts/docker/docker-config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class BuildContext {
case 'pull_request':
context.version = `pr-${pr}`;
context.release_type = 'dev';
context.push_to_ghcr = false;
context.platforms = ['linux/amd64'];
break;

case 'workflow_dispatch':
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Setup Node.js and Build
uses: ./.github/actions/setup-nodejs-github
uses: ./.github/actions/setup-nodejs
with:
build-command: pnpm build

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-documentation-urls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup Node.js
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs
with:
build-command: turbo build --filter=*nodes*

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
fetch-depth: 0

- name: Setup Node.js
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs
with:
build-command: pnpm run build --filter=@n8n/utils --filter=@n8n/vitest-config --filter=@n8n/design-system

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-evals.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
echo "LANGSMITH_DATASET_NAME=$DATASET" >> "$GITHUB_ENV"

- name: Setup and Build
uses: ./.github/actions/setup-nodejs-blacksmith
uses: ./.github/actions/setup-nodejs

- name: Install uv
uses: astral-sh/setup-uv@d9e0f98d3fc6adb07d1e3d37f3043649ddad06a1 # 6.5.0
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-manual-build-unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
ref: ${{ inputs.ref }}

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Run format check
run: pnpm format:check
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Setup and Build
uses: ./.github/actions/setup-nodejs-github
uses: ./.github/actions/setup-nodejs

unit-test:
name: Unit tests
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/ci-postgres-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ on:

concurrency:
group: db-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: false
cancel-in-progress: true

env:
NODE_OPTIONS: '--max-old-space-size=3072'
Expand All @@ -33,7 +33,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

sqlite-pooled:
name: SQLite Pooled
Expand All @@ -47,7 +47,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Test SQLite Pooled
working-directory: packages/cli
Expand All @@ -70,7 +70,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Start MariaDB
uses: isbang/compose-action@802a148945af6399a338c7906c267331b39a71af # v2.0.0
Expand Down Expand Up @@ -99,7 +99,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Start MySQL
uses: isbang/compose-action@802a148945af6399a338c7906c267331b39a71af # v2.0.0
Expand All @@ -124,7 +124,7 @@ jobs:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup and Build
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Start Postgres
uses: isbang/compose-action@802a148945af6399a338c7906c267331b39a71af # v2.0.0
Expand Down
33 changes: 21 additions & 12 deletions .github/workflows/ci-pull-requests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ name: Build, unit test and lint branch

on:
pull_request:
merge_group:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙌


concurrency:
group: ci-${{ github.event.pull_request.number || github.ref }}
group: ci-${{ github.event.pull_request.number || github.event.merge_group.head_sha || github.ref }}
cancel-in-progress: true

env:
Expand All @@ -19,10 +20,16 @@ jobs:
outputs:
frontend_changed: ${{ steps.paths-filter.outputs.frontend == 'true' }}
non_python_changed: ${{ steps.paths-filter.outputs.non-python == 'true' }}
commit_sha: ${{ steps.commit-sha.outputs.sha }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
# Use merge_group SHA when in merge queue, otherwise PR merge ref
ref: ${{ github.event_name == 'merge_group' && github.event.merge_group.head_sha || format('refs/pull/{0}/merge', github.event.pull_request.number) }}

- name: Capture commit SHA for cache consistency
id: commit-sha
run: echo "sha=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"

- name: Check for frontend changes
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
Expand All @@ -41,7 +48,7 @@ jobs:
- '!packages/@n8n/task-runner-python/**'
- name: Setup and Build
if: steps.paths-filter.outputs.non-python == 'true'
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Run format check
if: steps.paths-filter.outputs.non-python == 'true'
Expand All @@ -63,16 +70,16 @@ jobs:
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
ref: ${{ needs.install-and-build.outputs.commit_sha }}

- name: Setup pnpm CLI
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0

- name: Setup Node.js
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
with:
node-version: '22.x'
cache: pnpm
cache: 'pnpm'

- name: Install dependencies
run: pnpm install --frozen-lockfile
Expand All @@ -92,7 +99,7 @@ jobs:
uses: ./.github/workflows/units-tests-reusable.yml
needs: install-and-build
with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
ref: ${{ needs.install-and-build.outputs.commit_sha }}
collectCoverage: true
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Expand All @@ -105,10 +112,10 @@ jobs:
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
ref: ${{ needs.install-and-build.outputs.commit_sha }}

- name: Setup Node.js
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs
with:
build-command: pnpm typecheck

Expand All @@ -118,13 +125,15 @@ jobs:
uses: ./.github/workflows/linting-reusable.yml
needs: install-and-build
with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
ref: ${{ needs.install-and-build.outputs.commit_sha }}

e2e-tests:
name: E2E Tests
needs: [install-and-build]
needs: install-and-build
if: needs.install-and-build.outputs.non_python_changed == 'true'
uses: ./.github/workflows/playwright-test-ci.yml
with:
branch: ${{ needs.install-and-build.outputs.commit_sha }}
secrets: inherit

# This job is required by GitHub branch protection rules.
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/data-tooling.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
- packages/cli/**
- name: Setup, build and export sqlite
if: steps.paths-filter.outputs.db == 'true'
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs
with:
build-command: |
pnpm build
Expand Down Expand Up @@ -66,7 +66,7 @@ jobs:

- name: Setup and Build
if: steps.paths-filter.outputs.db == 'true'
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs

- name: Start Postgres
if: steps.paths-filter.outputs.db == 'true'
Expand Down
12 changes: 5 additions & 7 deletions .github/workflows/docker-build-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,10 @@ jobs:
fetch-depth: 0

- name: Setup and Build
uses: ./.github/actions/setup-nodejs-blacksmith
uses: ./.github/actions/setup-nodejs
with:
build-command: pnpm build:n8n
enable-docker-cache: 'true'

- name: Determine Docker tags for all images
id: determine-tags
Expand All @@ -104,9 +105,6 @@ jobs:
echo "${key}: ${value%%,*}..." # Show first tag for brevity
done

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0

- name: Login to GitHub Container Registry
if: needs.determine-build-context.outputs.push_enabled == 'true'
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
Expand All @@ -125,7 +123,7 @@ jobs:
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Build and push n8n Docker image
uses: useblacksmith/build-push-action@574eb0ee0b59c6a687ace24192f0727dfb65d6d7 # v1.2
uses: useblacksmith/build-push-action@30c71162f16ea2c27c3e21523255d209b8b538c1 # v2
with:
context: .
file: ./docker/images/n8n/Dockerfile
Expand All @@ -140,7 +138,7 @@ jobs:
tags: ${{ steps.determine-tags.outputs.n8n_tags }}

- name: Build and push task runners Docker image (Alpine)
uses: useblacksmith/build-push-action@574eb0ee0b59c6a687ace24192f0727dfb65d6d7 # v1.2
uses: useblacksmith/build-push-action@30c71162f16ea2c27c3e21523255d209b8b538c1 # v2
with:
context: .
file: ./docker/images/runners/Dockerfile
Expand All @@ -155,7 +153,7 @@ jobs:
tags: ${{ steps.determine-tags.outputs.runners_tags }}

- name: Build and push task runners Docker image (distroless)
uses: useblacksmith/build-push-action@574eb0ee0b59c6a687ace24192f0727dfb65d6d7 # v1.2
uses: useblacksmith/build-push-action@30c71162f16ea2c27c3e21523255d209b8b538c1 # v2
with:
context: .
file: ./docker/images/runners/Dockerfile.distroless
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linting-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
ref: ${{ inputs.ref }}

- name: Build and Test
uses: n8n-io/n8n/.github/actions/setup-nodejs-blacksmith@f5fbbbe0a28a886451c886cac6b49192a39b0eea # v1.104.1
uses: ./.github/actions/setup-nodejs
with:
build-command: pnpm lint
node-version: ${{ inputs.nodeVersion }}
Loading