From bfd469664cad0b9d714182bab4f22fb9b26fc768 Mon Sep 17 00:00:00 2001 From: shimritproj Date: Wed, 27 Dec 2023 18:31:23 +0200 Subject: [PATCH] Adding artifact names Adding artifact names for each collected log will help us understand which logs are suitable for each job. In the end, we will be able to see links in the GitHub UI for all artifact names, and there, all the logs suitable for each job will be accessible. Signed-off-by: shimritproj --- .github/workflows/ci.yaml | 12 ++++++++++++ .github/workflows/composite/collectlogs/action.yaml | 9 +++++++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3672c5090..2274720b0 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -96,6 +96,8 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: e2e olm: runs-on: ubuntu-20.04 @@ -140,6 +142,8 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: olm upgrade_version: runs-on: ubuntu-20.04 @@ -188,6 +192,8 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: upgrade_version - name: Checkout Latest Metal LB Operator uses: actions/checkout@v4 @@ -235,6 +241,8 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: upgrade_version metallb_e2e: runs-on: ubuntu-20.04 @@ -332,6 +340,8 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: metallb_e2e metallb_e2e_frr-k8s: runs-on: ubuntu-20.04 @@ -438,3 +448,5 @@ jobs: - name: Collect Logs if: ${{ failure() }} uses: ./.github/workflows/composite/collectlogs + with: + artifact-name: metallb_e2e_frr-k8s diff --git a/.github/workflows/composite/collectlogs/action.yaml b/.github/workflows/composite/collectlogs/action.yaml index 585912e1d..c9c9b311b 100644 --- a/.github/workflows/composite/collectlogs/action.yaml +++ b/.github/workflows/composite/collectlogs/action.yaml @@ -1,13 +1,18 @@ name: "collectlogs" description: "Collect and upload the logs" +inputs: + artifact-name: + description: "the name of artifacts to store" + required: true + runs: using: "composite" steps: - name: Archive E2E Tests logs uses: actions/upload-artifact@v2 with: - name: test_e2e_logs + name: ${{ inputs.artifact-name }}-e2e-logs path: /tmp/test_e2e_logs/ - name: Export kind logs @@ -23,5 +28,5 @@ runs: - name: Archive kind logs uses: actions/upload-artifact@v2 with: - name: kind_logs + name: ${{ inputs.artifact-name }}-kind-logs path: /tmp/kind_logs