From 835bc2aed873dcd258fe2db2ccea13e425b27708 Mon Sep 17 00:00:00 2001 From: Bassem Dghaidi <568794+Link-@users.noreply.github.com> Date: Wed, 11 Dec 2024 14:25:29 +0100 Subject: [PATCH] Fix ARC e2e tests (#3836) --- .../actions/execute-assert-arc-e2e/action.yaml | 17 +++++++++++++++-- .github/workflows/gha-e2e-tests.yaml | 16 ++++++++++++++++ 2 files changed, 31 insertions(+), 2 deletions(-) diff --git a/.github/actions/execute-assert-arc-e2e/action.yaml b/.github/actions/execute-assert-arc-e2e/action.yaml index 6aac8268..872d02d9 100644 --- a/.github/actions/execute-assert-arc-e2e/action.yaml +++ b/.github/actions/execute-assert-arc-e2e/action.yaml @@ -188,6 +188,19 @@ runs: } core.setFailed(`The triggered workflow run didn't finish properly using ${{inputs.arc-name}}`) + - name: Gather listener logs + shell: bash + if: always() + run: | + LISTENER_POD="$(kubectl get autoscalinglisteners.actions.github.com -n arc-systems -o jsonpath='{.items[*].metadata.name}')" + kubectl logs $LISTENER_POD -n ${{inputs.arc-controller-namespace}} + + - name: Gather coredns logs + shell: bash + if: always() + run: | + kubectl logs deployments/coredns -n kube-system + - name: cleanup if: inputs.wait-to-finish == 'true' shell: bash @@ -195,8 +208,8 @@ runs: helm uninstall ${{ inputs.arc-name }} --namespace ${{inputs.arc-namespace}} --debug kubectl wait --timeout=30s --for=delete AutoScalingRunnerSet -n ${{inputs.arc-namespace}} -l app.kubernetes.io/instance=${{ inputs.arc-name }} - - name: Gather logs and cleanup + - name: Gather controller logs shell: bash if: always() run: | - kubectl logs deployment/arc-gha-rs-controller -n ${{inputs.arc-controller-namespace}} + kubectl logs deployment/arc-gha-rs-controller -n ${{inputs.arc-controller-namespace}} \ No newline at end of file diff --git a/.github/workflows/gha-e2e-tests.yaml b/.github/workflows/gha-e2e-tests.yaml index cccc5ec1..867ed1db 100644 --- a/.github/workflows/gha-e2e-tests.yaml +++ b/.github/workflows/gha-e2e-tests.yaml @@ -103,6 +103,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -194,6 +196,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -284,6 +288,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -383,6 +389,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -484,6 +492,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -579,6 +589,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -699,6 +711,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Test ARC E2E uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10 @@ -789,6 +803,8 @@ jobs: kubectl wait --timeout=30s --for=condition=ready pod -n arc-systems -l actions.github.com/scale-set-name=$ARC_NAME kubectl get pod -n arc-systems + sleep 60 + - name: Trigger long running jobs and wait for runners to pick them up uses: ./.github/actions/execute-assert-arc-e2e timeout-minutes: 10