mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 04:34:06 -08:00
ci: Use turbo for build cache (no-changelog) (#9696)
This commit is contained in:
parent
bbb2296b3d
commit
b910ed6847
3
.github/workflows/ci-master.yml
vendored
3
.github/workflows/ci-master.yml
vendored
|
@ -23,6 +23,9 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|
||||||
|
|
14
.github/workflows/ci-postgres-mysql.yml
vendored
14
.github/workflows/ci-postgres-mysql.yml
vendored
|
@ -26,6 +26,9 @@ jobs:
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
- run: pnpm install --frozen-lockfile
|
- run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Build Backend
|
- name: Build Backend
|
||||||
run: pnpm build:backend
|
run: pnpm build:backend
|
||||||
|
|
||||||
|
@ -52,6 +55,9 @@ jobs:
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
- run: pnpm install --frozen-lockfile
|
- run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Restore cached build artifacts
|
- name: Restore cached build artifacts
|
||||||
uses: actions/cache/restore@v4.0.0
|
uses: actions/cache/restore@v4.0.0
|
||||||
with:
|
with:
|
||||||
|
@ -60,7 +66,7 @@ jobs:
|
||||||
|
|
||||||
- name: Test SQLite Pooled
|
- name: Test SQLite Pooled
|
||||||
working-directory: packages/cli
|
working-directory: packages/cli
|
||||||
run: pnpm jest --coverage
|
run: pnpm jest
|
||||||
|
|
||||||
mysql:
|
mysql:
|
||||||
name: MySQL
|
name: MySQL
|
||||||
|
@ -78,6 +84,9 @@ jobs:
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
- run: pnpm install --frozen-lockfile
|
- run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Restore cached build artifacts
|
- name: Restore cached build artifacts
|
||||||
uses: actions/cache/restore@v4.0.0
|
uses: actions/cache/restore@v4.0.0
|
||||||
with:
|
with:
|
||||||
|
@ -112,6 +121,9 @@ jobs:
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
- run: pnpm install --frozen-lockfile
|
- run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Restore cached build artifacts
|
- name: Restore cached build artifacts
|
||||||
uses: actions/cache/restore@v4.0.0
|
uses: actions/cache/restore@v4.0.0
|
||||||
with:
|
with:
|
||||||
|
|
3
.github/workflows/ci-pull-requests.yml
vendored
3
.github/workflows/ci-pull-requests.yml
vendored
|
@ -21,6 +21,9 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|
||||||
|
|
3
.github/workflows/linting-reusable.yml
vendored
3
.github/workflows/linting-reusable.yml
vendored
|
@ -33,6 +33,9 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
if: ${{ inputs.cacheKey == '' }}
|
if: ${{ inputs.cacheKey == '' }}
|
||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|
3
.github/workflows/units-tests-reusable.yml
vendored
3
.github/workflows/units-tests-reusable.yml
vendored
|
@ -49,6 +49,9 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Setup build cache
|
||||||
|
uses: rharkor/caching-for-turbo@v1.5
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
if: ${{ inputs.cacheKey == '' }}
|
if: ${{ inputs.cacheKey == '' }}
|
||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|
21
package.json
21
package.json
|
@ -11,27 +11,28 @@
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"preinstall": "node scripts/block-npm-install.js",
|
"preinstall": "node scripts/block-npm-install.js",
|
||||||
"build": "turbo run build",
|
"build": "turbo run build",
|
||||||
"build:backend": "pnpm --filter=!@n8n/chat --filter=!@n8n/codemirror-lang --filter=!n8n-design-system --filter=!n8n-editor-ui build",
|
"build:backend": "turbo run build:backend",
|
||||||
"build:frontend": "pnpm --filter=@n8n/chat --filter=@n8n/codemirror-lang --filter=n8n-design-system --filter=n8n-editor-ui build",
|
"build:frontend": "turbo run build:frontend",
|
||||||
"typecheck": "pnpm --filter=!n8n typecheck",
|
"build:nodes": "turbo run build:nodes",
|
||||||
|
"typecheck": "turbo --filter=!n8n typecheck",
|
||||||
"dev": "turbo run dev --parallel --filter=!n8n-design-system --filter=!@n8n/chat",
|
"dev": "turbo run dev --parallel --filter=!n8n-design-system --filter=!@n8n/chat",
|
||||||
"dev:ai": "turbo run dev --parallel --filter=@n8n/nodes-langchain --filter=n8n --filter=n8n-core",
|
"dev:ai": "turbo run dev --parallel --filter=@n8n/nodes-langchain --filter=n8n --filter=n8n-core",
|
||||||
"clean": "turbo run clean --parallel",
|
"clean": "turbo run clean --parallel",
|
||||||
"format": "turbo run format && node scripts/format.mjs",
|
"format": "turbo run format && node scripts/format.mjs",
|
||||||
"lint": "turbo run lint",
|
"lint": "turbo run lint",
|
||||||
"lintfix": "turbo run lintfix",
|
"lintfix": "turbo run lintfix",
|
||||||
"lint:backend": "pnpm --filter=!@n8n/chat --filter=!@n8n/codemirror-lang --filter=!n8n-design-system --filter=!n8n-editor-ui --filter=!n8n-nodes-base --filter=!@n8n/n8n-nodes-langchain lint",
|
"lint:backend": "turbo run lint:backend",
|
||||||
"lint:nodes": "pnpm --filter=n8n-nodes-base --filter=@n8n/n8n-nodes-langchain lint",
|
"lint:nodes": "turbo run lint:nodes",
|
||||||
"lint:frontend": "pnpm --filter=@n8n/chat --filter=@n8n/codemirror-lang --filter=n8n-design-system --filter=n8n-editor-ui lint",
|
"lint:frontend": "turbo run lint:frontend",
|
||||||
"optimize-svg": "find ./packages -name '*.svg' ! -name 'pipedrive.svg' -print0 | xargs -0 -P16 -L20 npx svgo",
|
"optimize-svg": "find ./packages -name '*.svg' ! -name 'pipedrive.svg' -print0 | xargs -0 -P16 -L20 npx svgo",
|
||||||
"start": "run-script-os",
|
"start": "run-script-os",
|
||||||
"start:default": "cd packages/cli/bin && ./n8n",
|
"start:default": "cd packages/cli/bin && ./n8n",
|
||||||
"start:tunnel": "./packages/cli/bin/n8n start --tunnel",
|
"start:tunnel": "./packages/cli/bin/n8n start --tunnel",
|
||||||
"start:windows": "cd packages/cli/bin && n8n",
|
"start:windows": "cd packages/cli/bin && n8n",
|
||||||
"test": "turbo run test",
|
"test": "turbo run test",
|
||||||
"test:backend": "pnpm --filter=!@n8n/chat --filter=!@n8n/codemirror-lang --filter=!n8n-design-system --filter=!n8n-editor-ui --filter=!n8n-nodes-base --filter=!@n8n/n8n-nodes-langchain test",
|
"test:backend": "turbo run test:backend --concurrency=1",
|
||||||
"test:nodes": "pnpm --filter=n8n-nodes-base --filter=@n8n/n8n-nodes-langchain test",
|
"test:frontend": "turbo run test:frontend --concurrency=1",
|
||||||
"test:frontend": "pnpm --filter=@n8n/chat --filter=@n8n/codemirror-lang --filter=n8n-design-system --filter=n8n-editor-ui test",
|
"test:nodes": "turbo run test:nodes --concurrency=1",
|
||||||
"watch": "turbo run watch --parallel",
|
"watch": "turbo run watch --parallel",
|
||||||
"webhook": "./packages/cli/bin/n8n webhook",
|
"webhook": "./packages/cli/bin/n8n webhook",
|
||||||
"worker": "./packages/cli/bin/n8n worker"
|
"worker": "./packages/cli/bin/n8n worker"
|
||||||
|
@ -55,7 +56,7 @@
|
||||||
"ts-jest": "^29.1.1",
|
"ts-jest": "^29.1.1",
|
||||||
"tsc-alias": "^1.8.7",
|
"tsc-alias": "^1.8.7",
|
||||||
"tsc-watch": "^6.0.4",
|
"tsc-watch": "^6.0.4",
|
||||||
"turbo": "1.13.3",
|
"turbo": "2.0.6",
|
||||||
"typescript": "*",
|
"typescript": "*",
|
||||||
"vite": "^5.2.12",
|
"vite": "^5.2.12",
|
||||||
"vitest": "^1.6.0",
|
"vitest": "^1.6.0",
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
"build:bundle": "INCLUDE_VUE=true vite build",
|
"build:bundle": "INCLUDE_VUE=true vite build",
|
||||||
"preview": "vite preview",
|
"preview": "vite preview",
|
||||||
"test:dev": "vitest",
|
"test:dev": "vitest",
|
||||||
"test": "vitest run --coverage",
|
"test": "vitest run",
|
||||||
"typecheck": "vue-tsc --noEmit",
|
"typecheck": "vue-tsc --noEmit",
|
||||||
"lint": "eslint . --ext .js,.ts,.vue --quiet",
|
"lint": "eslint . --ext .js,.ts,.vue --quiet",
|
||||||
"lintfix": "eslint . --ext .js,.ts,.vue --fix",
|
"lintfix": "eslint . --ext .js,.ts,.vue --fix",
|
||||||
|
|
|
@ -100,8 +100,8 @@ importers:
|
||||||
specifier: ^6.0.4
|
specifier: ^6.0.4
|
||||||
version: 6.0.4(typescript@5.5.2)
|
version: 6.0.4(typescript@5.5.2)
|
||||||
turbo:
|
turbo:
|
||||||
specifier: 1.13.3
|
specifier: 2.0.6
|
||||||
version: 1.13.3
|
version: 2.0.6
|
||||||
typescript:
|
typescript:
|
||||||
specifier: ^5.5.2
|
specifier: ^5.5.2
|
||||||
version: 5.5.2
|
version: 5.5.2
|
||||||
|
@ -12663,38 +12663,38 @@ packages:
|
||||||
resolution: {integrity: sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==}
|
resolution: {integrity: sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==}
|
||||||
engines: {node: '>=0.6.11 <=0.7.0 || >=0.7.3'}
|
engines: {node: '>=0.6.11 <=0.7.0 || >=0.7.3'}
|
||||||
|
|
||||||
turbo-darwin-64@1.13.3:
|
turbo-darwin-64@2.0.6:
|
||||||
resolution: {integrity: sha512-glup8Qx1qEFB5jerAnXbS8WrL92OKyMmg5Hnd4PleLljAeYmx+cmmnsmLT7tpaVZIN58EAAwu8wHC6kIIqhbWA==}
|
resolution: {integrity: sha512-XpgBwWj3Ggmz/gQVqXdMKXHC1iFPMDiuwugLwSzE7Ih0O13JuNtYZKhQnopvbDQnFQCeRq2Vsm5OTWabg/oB/g==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [darwin]
|
os: [darwin]
|
||||||
|
|
||||||
turbo-darwin-arm64@1.13.3:
|
turbo-darwin-arm64@2.0.6:
|
||||||
resolution: {integrity: sha512-/np2xD+f/+9qY8BVtuOQXRq5f9LehCFxamiQnwdqWm5iZmdjygC5T3uVSYuagVFsZKMvX3ycySwh8dylGTl6lg==}
|
resolution: {integrity: sha512-RfeZYXIAkiA21E8lsvfptGTqz/256YD+eI1x37fedfvnHFWuIMFZGAOwJxtZc6QasQunDZ9TRRREbJNI68tkIw==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [darwin]
|
os: [darwin]
|
||||||
|
|
||||||
turbo-linux-64@1.13.3:
|
turbo-linux-64@2.0.6:
|
||||||
resolution: {integrity: sha512-G+HGrau54iAnbXLfl+N/PynqpDwi/uDzb6iM9hXEDG+yJnSJxaHMShhOkXYJPk9offm9prH33Khx2scXrYVW1g==}
|
resolution: {integrity: sha512-92UDa0xNQQbx0HdSp9ag3YSS3xPdavhc7q9q9mxIAcqyjjD6VElA4Y85m4F/DDGE5SolCrvBz2sQhVmkOd6Caw==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
turbo-linux-arm64@1.13.3:
|
turbo-linux-arm64@2.0.6:
|
||||||
resolution: {integrity: sha512-qWwEl5VR02NqRyl68/3pwp3c/olZuSp+vwlwrunuoNTm6JXGLG5pTeme4zoHNnk0qn4cCX7DFrOboArlYxv0wQ==}
|
resolution: {integrity: sha512-eQKu6utCVUkIH2kqOzD8OS6E0ba6COjWm6PRDTNCHQRljZW503ycaTUIdMOiJrVg1MkEjDyOReUg8s8D18aJ4Q==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
turbo-windows-64@1.13.3:
|
turbo-windows-64@2.0.6:
|
||||||
resolution: {integrity: sha512-Nudr4bRChfJzBPzEmpVV85VwUYRCGKecwkBFpbp2a4NtrJ3+UP1VZES653ckqCu2FRyRuS0n03v9euMbAvzH+Q==}
|
resolution: {integrity: sha512-+9u4EPrpoeHYCQ46dRcou9kbkSoelhOelHNcbs2d86D6ruYD/oIAHK9qgYK8LeARRz0jxhZIA/dWYdYsxJJWkw==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
turbo-windows-arm64@1.13.3:
|
turbo-windows-arm64@2.0.6:
|
||||||
resolution: {integrity: sha512-ouJCgsVLd3icjRLmRvHQDDZnmGzT64GBupM1Y+TjtYn2LVaEBoV6hicFy8x5DUpnqdLy+YpCzRMkWlwhmkX7sQ==}
|
resolution: {integrity: sha512-rdrKL+p+EjtdDVg0wQ/7yTbzkIYrnb0Pw4IKcjsy3M0RqUM9UcEi67b94XOAyTa5a0GqJL1+tUj2ebsFGPgZbg==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
turbo@1.13.3:
|
turbo@2.0.6:
|
||||||
resolution: {integrity: sha512-n17HJv4F4CpsYTvKzUJhLbyewbXjq1oLCi90i5tW1TiWDz16ML1eDG7wi5dHaKxzh5efIM56SITnuVbMq5dk4g==}
|
resolution: {integrity: sha512-/Ftmxd5Mq//a9yMonvmwENNUN65jOVTwhhBPQjEtNZutYT9YKyzydFGLyVM1nzhpLWahQSMamRc/RDBv5EapzA==}
|
||||||
hasBin: true
|
hasBin: true
|
||||||
|
|
||||||
tween-functions@1.2.0:
|
tween-functions@1.2.0:
|
||||||
|
@ -27596,32 +27596,32 @@ snapshots:
|
||||||
|
|
||||||
tunnel@0.0.6: {}
|
tunnel@0.0.6: {}
|
||||||
|
|
||||||
turbo-darwin-64@1.13.3:
|
turbo-darwin-64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo-darwin-arm64@1.13.3:
|
turbo-darwin-arm64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo-linux-64@1.13.3:
|
turbo-linux-64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo-linux-arm64@1.13.3:
|
turbo-linux-arm64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo-windows-64@1.13.3:
|
turbo-windows-64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo-windows-arm64@1.13.3:
|
turbo-windows-arm64@2.0.6:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
turbo@1.13.3:
|
turbo@2.0.6:
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
turbo-darwin-64: 1.13.3
|
turbo-darwin-64: 2.0.6
|
||||||
turbo-darwin-arm64: 1.13.3
|
turbo-darwin-arm64: 2.0.6
|
||||||
turbo-linux-64: 1.13.3
|
turbo-linux-64: 2.0.6
|
||||||
turbo-linux-arm64: 1.13.3
|
turbo-linux-arm64: 2.0.6
|
||||||
turbo-windows-64: 1.13.3
|
turbo-windows-64: 2.0.6
|
||||||
turbo-windows-arm64: 1.13.3
|
turbo-windows-arm64: 2.0.6
|
||||||
|
|
||||||
tween-functions@1.2.0: {}
|
tween-functions@1.2.0: {}
|
||||||
|
|
||||||
|
|
63
turbo.json
63
turbo.json
|
@ -1,17 +1,74 @@
|
||||||
{
|
{
|
||||||
"$schema": "https://turborepo.org/schema.json",
|
"$schema": "https://turbo.build/schema.json",
|
||||||
"pipeline": {
|
"ui": "stream",
|
||||||
|
"tasks": {
|
||||||
"clean": {
|
"clean": {
|
||||||
"cache": false
|
"cache": false
|
||||||
},
|
},
|
||||||
|
"build:backend": {
|
||||||
|
"dependsOn": ["n8n#build"]
|
||||||
|
},
|
||||||
|
"build:frontend": {
|
||||||
|
"dependsOn": ["n8n-editor-ui#build"]
|
||||||
|
},
|
||||||
|
"build:nodes": {
|
||||||
|
"dependsOn": ["n8n-nodes-base#build", "@n8n/n8n-nodes-langchain#build"]
|
||||||
|
},
|
||||||
"build": {
|
"build": {
|
||||||
"dependsOn": ["^build"],
|
"dependsOn": ["^build"],
|
||||||
"outputs": ["dist/**"]
|
"outputs": ["dist/**"]
|
||||||
},
|
},
|
||||||
"typecheck": {},
|
"typecheck": {
|
||||||
|
"dependsOn": ["^typecheck"]
|
||||||
|
},
|
||||||
"format": {},
|
"format": {},
|
||||||
|
"lint:backend": {
|
||||||
|
"dependsOn": [
|
||||||
|
"@n8n/client-oauth2#lint",
|
||||||
|
"@n8n/imap#lint",
|
||||||
|
"@n8n/permissions#lint",
|
||||||
|
"n8n-workflow#lint",
|
||||||
|
"n8n-core#lint",
|
||||||
|
"n8n-node-dev#lint",
|
||||||
|
"n8n#lint"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"lint:frontend": {
|
||||||
|
"dependsOn": [
|
||||||
|
"@n8n/chat#lint",
|
||||||
|
"@n8n/codemirror-lang#lint",
|
||||||
|
"@n8n/storybook#lint",
|
||||||
|
"n8n-cypress#lint",
|
||||||
|
"n8n-design-system#lint",
|
||||||
|
"n8n-editor-ui#lint"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"lint:nodes": {
|
||||||
|
"dependsOn": ["n8n-nodes-base#lint", "@n8n/n8n-nodes-langchain#lint"]
|
||||||
|
},
|
||||||
"lint": {},
|
"lint": {},
|
||||||
"lintfix": {},
|
"lintfix": {},
|
||||||
|
"test:backend": {
|
||||||
|
"dependsOn": [
|
||||||
|
"@n8n/client-oauth2#test",
|
||||||
|
"@n8n/imap#test",
|
||||||
|
"@n8n/permissions#test",
|
||||||
|
"n8n-workflow#test",
|
||||||
|
"n8n-core#test",
|
||||||
|
"n8n#test"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"test:frontend": {
|
||||||
|
"dependsOn": [
|
||||||
|
"@n8n/chat#test",
|
||||||
|
"@n8n/codemirror-lang#test",
|
||||||
|
"n8n-design-system#test",
|
||||||
|
"n8n-editor-ui#test"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"test:nodes": {
|
||||||
|
"dependsOn": ["n8n-nodes-base#test", "@n8n/n8n-nodes-langchain#test"]
|
||||||
|
},
|
||||||
"test": {},
|
"test": {},
|
||||||
"watch": {
|
"watch": {
|
||||||
"cache": false,
|
"cache": false,
|
||||||
|
|
Loading…
Reference in a new issue