From 49b59124973743deea84463de022f777ce9e808f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Alm=C3=A1di?= Date: Wed, 10 Jan 2024 11:52:17 +0100 Subject: [PATCH] feat: switch to kyverno gh action --- .github/workflows/helm-lint-test.yaml | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/.github/workflows/helm-lint-test.yaml b/.github/workflows/helm-lint-test.yaml index 2c98abcc..c6fe10ca 100644 --- a/.github/workflows/helm-lint-test.yaml +++ b/.github/workflows/helm-lint-test.yaml @@ -44,10 +44,6 @@ on: default: 'latest' required: false type: string - -env: - KYVERNO_VERSION: v1.11.3 - PYTHON_VERSION: '3.10' jobs: list-changed: @@ -68,7 +64,7 @@ jobs: - uses: actions/setup-python@v5 with: - python-version: ${{ env.PYTHON_VERSION }} + python-version: '3.10' check-latest: true - name: Set up chart-testing @@ -100,7 +96,7 @@ jobs: - uses: actions/setup-python@v5 with: - python-version: ${{ env.PYTHON_VERSION }} + python-version: '3.10' check-latest: true - name: Kubernetes KinD Cluster @@ -157,12 +153,9 @@ jobs: run: | helm template chart-template charts/umbrella > charts/umbrella-template.yaml - - name: Download Kyverno CLI - run: | - curl -sLO https://github.com/kyverno/kyverno/releases/download/${{ env.KYVERNO_VERSION }}/kyverno-cli_${{ env.KYVERNO_VERSION }}_linux_x86_64.tar.gz - tar -xf kyverno-cli_${{ env.KYVERNO_VERSION }}_linux_x86_64.tar.gz - ${GITHUB_WORKSPACE}/kyverno version + - name: Install Kyverno CLI + uses: kyverno/action-install-cli@v0.2.0 - name: Test new resources against existing policies - run: ${GITHUB_WORKSPACE}/kyverno apply .github/kyverno-policies/require-run-as-nonroot.yaml -r charts/umbrella-template.yaml + run: kyverno apply .github/kyverno-policies/require-run-as-nonroot.yaml -r charts/umbrella-template.yaml