Skip to content

Commit

Permalink
build: use also different K8s versions for E2E testing in GHA (kubefl…
Browse files Browse the repository at this point in the history
…ow#659)

* build: use also different K8s versions for E2E testing in GHA

Signed-off-by: Matteo Mortari <[email protected]>

* refactor matrix GHA

Signed-off-by: Matteo Mortari <[email protected]>

* demo on PR how it would look on main merges

Signed-off-by: Matteo Mortari <[email protected]>

* revert as intentended on PR

Revert "demo on PR how it would look on main merges"

This reverts commit ecd8778.

Signed-off-by: Matteo Mortari <[email protected]>

* add K8s version on suggestion by Andrey

Signed-off-by: Matteo Mortari <[email protected]>

---------

Signed-off-by: Matteo Mortari <[email protected]>
  • Loading branch information
tarilabs authored Dec 18, 2024
1 parent ba5b6cb commit a4e3600
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions .github/workflows/python-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,25 @@ jobs:
fi
test:
name: Test against Py ${{ matrix.python }}
name: Test against Py ${{ matrix.python }} and K8s ${{ matrix.kubernetes-version }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python: ["3.12", "3.11", "3.10", "3.9"]
python: ["3.12"] # see below for versions 3.9-3.11
kubernetes-version: ["v1.27.11", "v1.28.7", "v1.29.2", "v1.30.6", "v1.31.0"]
exclude: # on main merges (not PRs), use also different K8s versions for E2E testing
- kubernetes-version: ${{ github.event_name != 'push' && 'v1.28.7' }}
- kubernetes-version: ${{ github.event_name != 'push' && 'v1.29.2' }}
- kubernetes-version: ${{ github.event_name != 'push' && 'v1.30.6' }}
- kubernetes-version: ${{ github.event_name != 'push' && 'v1.31.0' }}
include: # test Py versions only with a reference K8s version, designated currently to kubernetes-version: v1.27.11
- python: "3.11"
kubernetes-version: "v1.27.11"
- python: "3.10"
kubernetes-version: "v1.27.11"
- python: "3.9"
kubernetes-version: "v1.27.11"
env:
FORCE_COLOR: "1"
IMG_ORG: kubeflow
Expand Down Expand Up @@ -124,8 +137,9 @@ jobs:
- name: Start Kind Cluster
uses: helm/[email protected]
with:
node_image: "kindest/node:v1.27.11"
node_image: kindest/node:${{ matrix.kubernetes-version }}
cluster_name: chart-testing-py-${{ matrix.python }}
kubectl_version: ${{ matrix.kubernetes-version }}
- name: Load Local Registry Test Image
env:
IMG: "${{ env.IMG_ORG }}/${{ env.IMG_REPO }}:${{ steps.tags.outputs.tag }}"
Expand Down

0 comments on commit a4e3600

Please sign in to comment.