11name : E2E Test
22
33on :
4- workflow_dispatch :
5- inputs :
6- image-tag :
7- description : " Image tag to test (typically the commit SHA)"
8- required : false
9- type : string
10- default : " "
11- runner :
12- description : " GitHub Actions runner label"
13- required : false
14- type : string
15- default : " build-amd64"
16- suite :
17- description : " E2E suite to run"
18- required : false
19- type : choice
20- default : all
21- options :
22- - all
23- - python-gpu
244 workflow_call :
255 inputs :
266 image-tag :
3212 required : false
3313 type : string
3414 default : " build-amd64"
35- suite :
36- description : " E2E suite to run"
37- required : false
38- type : string
39- default : " all"
4015
4116permissions :
4217 contents : read
@@ -45,7 +20,6 @@ permissions:
4520jobs :
4621 e2e :
4722 name : " E2E (${{ matrix.suite }})"
48- if : inputs.suite != 'python-gpu'
4923 runs-on : ${{ inputs.runner }}
5024 timeout-minutes : 30
5125 strategy :
7448 - /var/run/docker.sock:/var/run/docker.sock
7549 env :
7650 MISE_GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
77- IMAGE_TAG : ${{ inputs.image-tag || github.sha }}
51+ IMAGE_TAG : ${{ inputs.image-tag }}
7852 OPENSHELL_REGISTRY : ghcr.io/nvidia/openshell
7953 OPENSHELL_REGISTRY_HOST : ghcr.io
8054 OPENSHELL_REGISTRY_NAMESPACE : nvidia/openshell
@@ -88,18 +62,18 @@ jobs:
8862 run : echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u "${{ github.actor }}" --password-stdin
8963
9064 - name : Pull cluster image
91- run : docker pull ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag || github.sha }}
65+ run : docker pull ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag }}
9266
9367 - name : Install Python dependencies and generate protobuf stubs
9468 if : matrix.suite == 'python'
9569 run : uv sync --frozen && mise run --no-prepare python:proto
9670
9771 - name : Build Rust CLI
98- if : matrix.suite == 'rust' || matrix.suite == 'gateway-resume '
72+ if : matrix.suite != 'python '
9973 run : cargo build -p openshell-cli --features openshell-core/dev-settings
10074
10175 - name : Install SSH client
102- if : matrix.suite == 'rust' || matrix.suite == 'gateway-resume '
76+ if : matrix.suite != 'python '
10377 run : apt-get update && apt-get install -y --no-install-recommends openssh-client && rm -rf /var/lib/apt/lists/*
10478
10579 - name : Bootstrap cluster
@@ -109,56 +83,8 @@ jobs:
10983 CLUSTER_NAME : ${{ matrix.cluster }}
11084 SKIP_IMAGE_PUSH : " 1"
11185 SKIP_CLUSTER_IMAGE_BUILD : " 1"
112- OPENSHELL_CLUSTER_IMAGE : ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag || github.sha }}
86+ OPENSHELL_CLUSTER_IMAGE : ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag }}
11387 run : mise run --no-prepare --skip-deps cluster
11488
11589 - name : Run tests
11690 run : ${{ matrix.cmd }}
117-
118- e2e-gpu :
119- name : " E2E (python-gpu)"
120- if : inputs.suite == 'python-gpu'
121- runs-on : ${{ inputs.runner }}
122- timeout-minutes : 30
123- container :
124- image : ghcr.io/nvidia/openshell/ci:latest
125- credentials :
126- username : ${{ github.actor }}
127- password : ${{ secrets.GITHUB_TOKEN }}
128- options : --privileged
129- volumes :
130- - /var/run/docker.sock:/var/run/docker.sock
131- env :
132- MISE_GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
133- IMAGE_TAG : ${{ inputs.image-tag || github.sha }}
134- OPENSHELL_REGISTRY : ghcr.io/nvidia/openshell
135- OPENSHELL_REGISTRY_HOST : ghcr.io
136- OPENSHELL_REGISTRY_NAMESPACE : nvidia/openshell
137- OPENSHELL_REGISTRY_USERNAME : ${{ github.actor }}
138- OPENSHELL_REGISTRY_PASSWORD : ${{ secrets.GITHUB_TOKEN }}
139- OPENSHELL_GATEWAY : e2e-gpu
140- steps :
141- - uses : actions/checkout@v4
142-
143- - name : Log in to GHCR
144- run : echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u "${{ github.actor }}" --password-stdin
145-
146- - name : Pull cluster image
147- run : docker pull ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag || github.sha }}
148-
149- - name : Install Python dependencies and generate protobuf stubs
150- run : uv sync --frozen && mise run --no-prepare python:proto
151-
152- - name : Bootstrap GPU cluster
153- env :
154- GATEWAY_HOST : host.docker.internal
155- GATEWAY_PORT : " 8083"
156- CLUSTER_NAME : e2e-gpu
157- CLUSTER_GPU : " 1"
158- SKIP_IMAGE_PUSH : " 1"
159- SKIP_CLUSTER_IMAGE_BUILD : " 1"
160- OPENSHELL_CLUSTER_IMAGE : ghcr.io/nvidia/openshell/cluster:${{ inputs.image-tag || github.sha }}
161- run : mise run --no-prepare --skip-deps cluster
162-
163- - name : Run tests
164- run : mise run --no-prepare --skip-deps e2e:python:gpu
0 commit comments