Skip to content

Commit 9e447ff

Browse files
authored
ci: speed up E2E pipeline by running on arm64 runners and skipping redundant cluster rebuild (#278)
1 parent 1b3af84 commit 9e447ff

File tree

3 files changed

+24
-3
lines changed

3 files changed

+24
-3
lines changed

.github/workflows/docker-build.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,16 @@ on:
1717
required: false
1818
type: boolean
1919
default: true
20+
platform:
21+
description: "Target platform(s) for Docker build"
22+
required: false
23+
type: string
24+
default: "linux/amd64,linux/arm64"
25+
runner:
26+
description: "GitHub Actions runner label"
27+
required: false
28+
type: string
29+
default: "build-amd64"
2030

2131
env:
2232
MISE_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -29,7 +39,7 @@ permissions:
2939
jobs:
3040
build:
3141
name: Build ${{ inputs.component }}
32-
runs-on: build-amd64
42+
runs-on: ${{ inputs.runner }}
3343
timeout-minutes: ${{ inputs.timeout-minutes }}
3444
container:
3545
image: ghcr.io/nvidia/openshell/ci:latest
@@ -43,7 +53,7 @@ jobs:
4353
IMAGE_TAG: ${{ github.sha }}
4454
IMAGE_REGISTRY: ghcr.io/nvidia/openshell
4555
DOCKER_PUSH: ${{ inputs.push && '1' || '0' }}
46-
DOCKER_PLATFORM: linux/amd64,linux/arm64
56+
DOCKER_PLATFORM: ${{ inputs.platform }}
4757
steps:
4858
- uses: actions/checkout@v4
4959
with:

.github/workflows/e2e-test.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ on:
77
description: "Image tag to test (typically the commit SHA)"
88
required: true
99
type: string
10+
runner:
11+
description: "GitHub Actions runner label"
12+
required: false
13+
type: string
14+
default: "build-amd64"
1015

1116
permissions:
1217
contents: read
@@ -15,7 +20,7 @@ permissions:
1520
jobs:
1621
e2e:
1722
name: E2E
18-
runs-on: build-amd64
23+
runs-on: ${{ inputs.runner }}
1924
timeout-minutes: 30
2025
container:
2126
image: ghcr.io/nvidia/openshell/ci:latest
@@ -50,6 +55,7 @@ jobs:
5055
GATEWAY_HOST: host.docker.internal
5156
GATEWAY_PORT: "8080"
5257
SKIP_IMAGE_PUSH: "1"
58+
SKIP_CLUSTER_IMAGE_BUILD: "1"
5359
OPENSHELL_CLUSTER_IMAGE: ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag }}
5460
run: mise run --no-prepare --skip-deps cluster
5561

.github/workflows/e2e.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,20 @@ jobs:
1414
uses: ./.github/workflows/docker-build.yml
1515
with:
1616
component: gateway
17+
platform: linux/arm64
18+
runner: build-arm64
1719

1820
build-cluster:
1921
if: contains(github.event.pull_request.labels.*.name, 'e2e')
2022
uses: ./.github/workflows/docker-build.yml
2123
with:
2224
component: cluster
25+
platform: linux/arm64
26+
runner: build-arm64
2327

2428
e2e:
2529
needs: [build-gateway, build-cluster]
2630
uses: ./.github/workflows/e2e-test.yml
2731
with:
2832
image-tag: ${{ github.sha }}
33+
runner: build-arm64

0 commit comments

Comments
 (0)