Skip to content

docker(deps): bump kyma-project/prod/external/golang (#285) #3

docker(deps): bump kyma-project/prod/external/golang (#285)

docker(deps): bump kyma-project/prod/external/golang (#285) #3

# Jobs defined in this file are resposible for all kinds of integration tests
# Those tests depend on a container image so in the first job we wait for the image build to succeed
name: Pull Request integration tests
on:
pull_request:
types: [synchronize, opened, reopened, ready_for_review]
paths-ignore:
- "docs/**"
- "**/*.md"
- "tests/performance/**"
- "OWNERS"
- "CODEOWNERS"
- "sec-scanners-config.yaml"
- ".github/**" #Ignoring since build job isn't triggered on the workflow directory changes
branches:
- main
- 'release-**'
push:
paths-ignore:
- "docs/**"
- "**/*.md"
- "tests/performance/**"
- "OWNERS"
- "CODEOWNERS"
- "sec-scanners-config.yaml"
- ".github/**" #Ignoring since build job isn't triggered on the workflow directory changes
branches:
- main
permissions:
contents: read
jobs:
wait-for-image-build:
name: Wait for image build
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
steps:
- uses: autotelic/action-wait-for-status-check@6556cf50c8fb6608412945382eae73581f56cbb4
name: Wait for build to succeed
id: wait-for-status
with:
token: ${{ secrets.GITHUB_TOKEN }}
statusName: "pull-istio-operator-build"
timeoutSeconds: "1800"
- name: Check that build status is success
if: steps.wait-for-status.outputs.state != 'success'
run: exit 1
k8s-compatibility-test:
name: Kubernetes version compatibility check
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
needs: [wait-for-image-build]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.20"
- uses: AbsaOSS/k3d-action@4e8b3239042be1dc0aed6c5eb80c13b18200fc79 #v2.4.0
name: "Create Single Cluster"
with:
cluster-name: "test-cluster-1"
args: >-
--agents 2
--image docker.io/rancher/k3s:v1.27.3-k3s1
--servers-memory=16g
--port 80:80@loadbalancer
--port 443:443@loadbalancer
--k3s-arg "--disable=traefik@server:0"
- name: Run integration tests
run: |
kubectl config use-context k3d-test-cluster-1
EXPORT_RESULT=true IMG=europe-docker.pkg.dev/kyma-project/dev/istio-manager:PR-${{github.event.number}} make istio-integration-test
- name: Check deprecations
run: |
set -eou pipefail
GO111MODULE=on go install github.com/prometheus/prom2json/cmd/[email protected]
kubectl get --context k3d-test-cluster-1 --raw /metrics | prom2json | jq '.[] | select(.name=="apiserver_requested_deprecated_apis").metrics[].labels' > deprecations.txt
- uses: actions/upload-artifact@v3
with:
name: html-reports
path: tests/integration/reports/
- uses: actions/upload-artifact@v3
with:
name: deprecation-report
path: deprecations.txt
- run: if [[ $(wc -l deprecations.txt | awk '{print $1}' ) != '0' ]]; then exit 1; fi
name: Check that deprecations are empty
istio-upgrade-integration-test:
name: Istio upgrade integration test
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
needs: [wait-for-image-build]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.20"
- uses: AbsaOSS/k3d-action@4e8b3239042be1dc0aed6c5eb80c13b18200fc79 #v2.4.0
name: "Create Single Cluster"
with:
cluster-name: "test-cluster-1"
args: >-
--agents 0
--k3s-arg "--disable=traefik@server:0"
- name: Run upgrade integration test
run: |
kubectl config use-context k3d-test-cluster-1
EXPORT_RESULT=true IMG=europe-docker.pkg.dev/kyma-project/dev/istio-manager:PR-${{github.event.number}} TARGET_BRANCH=${{github.base_ref}} make istio-upgrade-integration-test