2022-10-20 12:17:33 +00:00
|
|
|
name: Conformance tests
|
2023-01-02 20:51:18 +00:00
|
|
|
|
2022-10-20 12:17:33 +00:00
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- 'main'
|
|
|
|
- 'release*'
|
|
|
|
|
2022-11-23 13:29:57 +00:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2022-10-20 12:17:33 +00:00
|
|
|
jobs:
|
2022-11-04 14:00:31 +00:00
|
|
|
run-conformance:
|
2022-12-21 10:14:53 +00:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
k8s-version: [v1.24.7, v1.25.3, v1.26.0]
|
2022-10-20 12:17:33 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-12-13 14:01:51 +00:00
|
|
|
uses: actions/checkout@755da8c3cf115ac066823e79a1e1788f8940201b # v3.2.0
|
2022-10-20 12:17:33 +00:00
|
|
|
- name: Unshallow
|
|
|
|
run: git fetch --prune --unshallow
|
|
|
|
- name: Setup go
|
2022-12-14 08:47:55 +00:00
|
|
|
uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # v3.5.0
|
2022-10-20 12:17:33 +00:00
|
|
|
with:
|
2022-12-20 13:51:55 +00:00
|
|
|
go-version: ~1.19.4
|
2022-11-07 18:01:25 +00:00
|
|
|
- name: Prepare environment
|
2022-12-21 10:14:53 +00:00
|
|
|
run: |
|
|
|
|
export KIND_IMAGE=kindest/node:${{ matrix.k8s-version }}
|
|
|
|
make kind-create-cluster kind-deploy-kyverno
|
2022-11-04 14:00:31 +00:00
|
|
|
- name: Wait for Kyverno to start
|
|
|
|
run: sleep 60
|
|
|
|
- name: Test with kuttl
|
2022-11-07 18:01:25 +00:00
|
|
|
run: make test-kuttl
|
2022-11-14 20:34:56 +00:00
|
|
|
- name: Debug failure
|
|
|
|
if: failure()
|
|
|
|
run: |
|
|
|
|
kubectl get mutatingwebhookconfigurations,validatingwebhookconfigurations
|
|
|
|
kubectl -n kyverno get pod
|
|
|
|
kubectl -n kyverno describe pod | grep -i events -A10
|
2022-12-11 21:22:06 +00:00
|
|
|
kubectl -n kyverno logs deploy/kyverno --all-containers -p || true
|
|
|
|
kubectl -n kyverno logs deploy/kyverno --all-containers
|
2022-12-12 18:39:29 +00:00
|
|
|
kubectl -n kyverno logs deploy/kyverno-cleanup-controller --all-containers -p || true
|
|
|
|
kubectl -n kyverno logs deploy/kyverno-cleanup-controller --all-containers
|