From cdd5c85f67497c75f7b475e79cc8df59d44a6e92 Mon Sep 17 00:00:00 2001 From: Joey Liu Date: Fri, 14 Feb 2025 21:24:26 +0000 Subject: [PATCH] Enable overwrite on upload artifact Signed-off-by: Joey Liu --- .github/workflows/build_and_test_workflow.yml | 4 ++++ .github/workflows/cypress_workflow.yml | 14 ++++++++++---- .github/workflows/cypress_workflow_with_s3.yml | 7 +++++-- .github/workflows/release_cypress_workflow.yml | 4 +++- 4 files changed, 22 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build_and_test_workflow.yml b/.github/workflows/build_and_test_workflow.yml index 344450cb0edf..61647bba3204 100644 --- a/.github/workflows/build_and_test_workflow.yml +++ b/.github/workflows/build_and_test_workflow.yml @@ -312,6 +312,7 @@ jobs: path: | test/*/failure_debug/ test/*/screenshots/ + overwrite: true plugin-functional-tests: name: Run plugin functional tests on ${{ matrix.name }} @@ -423,6 +424,7 @@ jobs: path: | test/*/failure_debug/ test/*/screenshots/ + overwrite: true build-min-artifact-tests: name: Build min release artifacts on ${{ matrix.name }} @@ -535,6 +537,7 @@ jobs: name: ${{ matrix.suffix }}-${{ env.VERSION }} path: ./artifacts/target/${{ env.ARTIFACT_BUILD_NAME }} retention-days: 1 + overwrite: true bwc-tests: needs: [build-min-artifact-tests] @@ -627,3 +630,4 @@ jobs: ./artifacts/bwc_tmp/test/cypress/screenshots/* ./artifacts/bwc_tmp/test/cypress/results/* retention-days: 1 + overwrite: true diff --git a/.github/workflows/cypress_workflow.yml b/.github/workflows/cypress_workflow.yml index a1521c43be5d..a7eb5616c965 100644 --- a/.github/workflows/cypress_workflow.yml +++ b/.github/workflows/cypress_workflow.yml @@ -92,7 +92,7 @@ jobs: # Dashboard tests with query enhanced - group 3 - group: 13 config: query_enhanced - test_location: source + test_location: source # Dashboard tests with query enhanced - group 4 - group: 14 config: query_enhanced @@ -100,7 +100,7 @@ jobs: # Dashboard tests with query enhanced - group 5 - group: 15 config: query_enhanced - test_location: source + test_location: source container: image: docker://opensearchstaging/ci-runner:ci-runner-rockylinux8-opensearch-dashboards-integtest-v2 options: --user 1001 @@ -282,14 +282,16 @@ jobs: name: ftr-cypress-screenshots-${{ matrix.group }} path: ${{ env.FTR_PATH }}/cypress/screenshots retention-days: 1 + overwrite: true - name: Upload FT repo videos uses: actions/upload-artifact@v4 - if: always() && matrix.test_location == 'ftr' + if: failure() && matrix.test_location == 'ftr' with: name: ftr-cypress-videos-${{ matrix.group }} path: ${{ env.FTR_PATH }}/cypress/videos retention-days: 1 + overwrite: true - name: Upload FT repo results uses: actions/upload-artifact@v4 @@ -298,6 +300,7 @@ jobs: name: ftr-cypress-results-${{ matrix.group }} path: ${{ env.FTR_PATH }}/cypress/results retention-days: 1 + overwrite: true - name: Upload Dashboards screenshots if: failure() && matrix.test_location == 'source' @@ -306,14 +309,16 @@ jobs: name: dashboards-cypress-screenshots-${{ matrix.group }} path: cypress/screenshots retention-days: 1 + overwrite: true - name: Upload Dashboards repo videos uses: actions/upload-artifact@v4 - if: always() && matrix.test_location == 'source' + if: failure() && matrix.test_location == 'source' with: name: dashboards-cypress-videos-${{ matrix.group }} path: cypress/videos retention-days: 1 + overwrite: true - name: Upload Dashboards repo results uses: actions/upload-artifact@v4 @@ -322,6 +327,7 @@ jobs: name: dashboards-cypress-results-${{ matrix.group }} path: cypress/results retention-days: 1 + overwrite: true add-comment: needs: [cypress-tests] diff --git a/.github/workflows/cypress_workflow_with_s3.yml b/.github/workflows/cypress_workflow_with_s3.yml index 08bffcedc8ec..7b86c93817d2 100644 --- a/.github/workflows/cypress_workflow_with_s3.yml +++ b/.github/workflows/cypress_workflow_with_s3.yml @@ -130,14 +130,16 @@ jobs: name: dashboards-cypress-screenshots-10 path: cypress/screenshots retention-days: 1 + overwrite: true - name: Upload Dashboards repo videos uses: actions/upload-artifact@v4 - if: always() + if: failure() with: name: dashboards-cypress-videos-10 path: cypress/videos retention-days: 1 + overwrite: true - name: Upload Dashboards repo results uses: actions/upload-artifact@v4 @@ -145,4 +147,5 @@ jobs: with: name: dashboards-cypress-results-10 path: cypress/results - retention-days: 1 \ No newline at end of file + retention-days: 1 + overwrite: true diff --git a/.github/workflows/release_cypress_workflow.yml b/.github/workflows/release_cypress_workflow.yml index bb9895d9f048..0c22be97c8a1 100644 --- a/.github/workflows/release_cypress_workflow.yml +++ b/.github/workflows/release_cypress_workflow.yml @@ -150,10 +150,12 @@ jobs: name: release-osd-cypress-screenshots-${{ matrix.spec_group }} path: ${{ env.OSD_PATH }}/cypress/screenshots retention-days: 1 + overwrite: true - uses: actions/upload-artifact@v4 - if: always() + if: failure() with: name: release-osd-cypress-videos-${{ matrix.spec_group }} path: ${{ env.OSD_PATH }}/cypress/videos retention-days: 1 + overwrite: true