Skip to content

Commit

Permalink
chore: fix ci (remove parallel) and update agents config
Browse files Browse the repository at this point in the history
  • Loading branch information
tinesoft committed Dec 31, 2024
1 parent 4eafd5a commit 096503e
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:

# Connect your workspace on nx.app and uncomment this to enable task distribution.
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e" targets have been requested
- run: pnpm exec nx-cloud start-ci-run --distribute-on=".nx/workflows/dynamic-changesets.yaml" --stop-agents-after="e2e-ci" --with-env-vars="ANDROID_SDK_VERSION,FLUTTER_VERSION,JDK_VERSION"
- run: pnpm exec nx-cloud start-ci-run --distribute-on=".nx/workflows/distribution-config.yaml" --stop-agents-after="e2e-ci" --with-env-vars="ANDROID_SDK_VERSION,FLUTTER_VERSION,JDK_VERSION"

# This line is needed for nx affected to work when CI is running on a PR
- run: git branch --track develop origin/develop || exit 0
Expand Down
2 changes: 1 addition & 1 deletion .nx/workflows/agents.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
launch-templates:
linux-medium-js-java-flutter:
resource-class: 'docker_linux_amd64/large'
resource-class: 'docker_linux_amd64/medium+'
image: 'ubuntu22.04-node20.11-v10'
init-steps:
- name: Checkout
Expand Down
21 changes: 21 additions & 0 deletions .nx/workflows/distribution-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
distribute-on:
small-changeset: 2 linux-large-js, 4 linux-medium-js-java-flutter, 2 linux-medium-js
medium-changeset: 3 linux-large-js, 6 linux-medium-js-java-flutter, 5 linux-medium-js
large-changeset: 4 linux-large-js, 8 linux-medium-js-java-flutter, 8 linux-medium-js

assignment-rules:
- target: build
runs-on:
- linux-large-js

- target: e2e
runs-on:
- linux-medium-js-java-flutter

- target: test
runs-on:
- linux-medium-js

- target: lint
runs-on:
- linux-medium-js
4 changes: 0 additions & 4 deletions .nx/workflows/dynamic-changesets.yaml

This file was deleted.

6 changes: 4 additions & 2 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@
"plugin": "@nx/jest/plugin",
"options": {
"targetName": "e2e",
"ciTargetName": "e2e-ci"
"ciTargetName": "e2e-ci",
"disableJestRuntime": false
},
"include": [
"e2e/nx-flutter-e2e/**/*",
Expand All @@ -127,7 +128,8 @@
"plugin": "@nx/jest/plugin",
"options": {
"targetName": "test",
"ciTargetName": "test-ci"
"ciTargetName": "test-ci",
"disableJestRuntime": false
},
"include": [
"packages/common/**/*",
Expand Down

0 comments on commit 096503e

Please sign in to comment.