Skip to content

Commit 5ed72d9

Browse files
committed
ci(integrations): fix kind version on alt trigger
Signed-off-by: Árpád Csepi <[email protected]>
1 parent a88f01d commit 5ed72d9

File tree

1 file changed

+22
-11
lines changed

1 file changed

+22
-11
lines changed

.github/workflows/test-integrations.yaml

+22-11
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,32 @@ on:
99
pull_request:
1010
workflow_dispatch:
1111
inputs:
12-
destroy-cluster:
13-
description: 'Destroy test cluster'
14-
required: false
15-
default: true
16-
type: boolean
17-
python-version:
18-
description: 'Python version to install'
19-
required: false
20-
default: '3.12'
2112
kind-version:
2213
description: 'Kind version'
2314
required: false
2415
default: '0.24.0'
2516

2617
jobs:
18+
set-kind-version:
19+
runs-on: ubuntu-latest
20+
outputs:
21+
kind-version: ${{steps.set-kind-version.outputs.kind-version }}
22+
steps:
23+
- name: Set KinD version
24+
id: set-kind-version
25+
env:
26+
KIND_VERSION: '0.24.0'
27+
shell: bash
28+
run: |
29+
if [ "${{ github.event_name }}" == 'workflow_dispatch' ]; then
30+
KIND_VERSION="${{ inputs.kind-version }}"
31+
fi
32+
33+
echo "Set KinD version to: $KIND_VERSION"
34+
echo "kind-version=$KIND_VERSION" >> "$GITHUB_OUTPUT"
35+
2736
run-tests-gateway:
37+
needs: [ set-kind-version ]
2838
runs-on: ubuntu-latest
2939

3040
permissions:
@@ -55,7 +65,7 @@ jobs:
5565
- name: Setup K8S Tools
5666
uses: ./.github/actions/setup-k8s
5767
with:
58-
kind-version: ${{ inputs.kind-version }}
68+
kind-version: ${{ needs.set-kind-version.outputs.kind-version }}
5969

6070
- name: Create kind cluster
6171
run: task integrations:kind:create
@@ -76,6 +86,7 @@ jobs:
7686
shell: bash
7787

7888
run-tests-directory:
89+
needs: [ set-kind-version ]
7990
runs-on: ubuntu-latest
8091

8192
permissions:
@@ -106,7 +117,7 @@ jobs:
106117
- name: Setup K8S Tools
107118
uses: ./.github/actions/setup-k8s
108119
with:
109-
kind-version: ${{ inputs.kind-version }}
120+
kind-version: ${{ needs.set-kind-version.outputs.kind-version }}
110121

111122
- name: Create kind cluster
112123
run: task integrations:kind:create

0 commit comments

Comments
 (0)