Zip build artifacts before uploading (#2129)

* fix

* fix path

* Use PS commands

* fix

* fix ossar yaml

* for testing, revert later

* Revert "for testing, revert later"

This reverts commit 5ef51d4249.

* cleanup

* fix
This commit is contained in:
Anurag Saxena 2023-02-24 10:19:53 -08:00 коммит произвёл GitHub
Родитель 179ec1b429
Коммит f87854dde8
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
3 изменённых файлов: 26 добавлений и 6 удалений

11
.github/workflows/ossar-scan.yml поставляемый
Просмотреть файл

@ -53,8 +53,15 @@ jobs:
uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
id: download_artifact
with:
name: ${{inputs.build_artifact}} ${{matrix.configurations}}
path: ${{github.workspace}}/${{env.BUILD_PLATFORM}}/${{env.BUILD_CONFIGURATION}}
name: ${{inputs.build_artifact}}-${{matrix.configurations}}
path: ${{github.workspace}}
- name: Extract build artifact
if: steps.skip_check.outputs.should_skip != 'true'
working-directory: ${{github.workspace}}
run: |
mkdir ${{env.BUILD_PLATFORM}}
Expand-Archive .\build-${{ matrix.configurations }}.zip -DestinationPath .\${{env.BUILD_PLATFORM}}
- name: Exclude external files
if: steps.skip_check.outputs.should_skip != 'true'

10
.github/workflows/reusable-build.yml поставляемый
Просмотреть файл

@ -174,12 +174,18 @@ jobs:
cd ${{github.workspace}}/${{env.BUILD_PLATFORM}}/${{env.BUILD_CONFIGURATION}}
tar -xf ..\..\x64-${{ matrix.configurations }}-cilium-xdp.zip
- name: Zip Build Output
if: steps.skip_check.outputs.should_skip != 'true'
working-directory: ${{github.workspace}}
run: |
Compress-Archive -Path ${{env.BUILD_PLATFORM}}\${{env.BUILD_CONFIGURATION}} -DestinationPath .\build-${{ matrix.configurations }}.zip
- name: Upload Build Output
if: steps.skip_check.outputs.should_skip != 'true'
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
with:
name: ${{inputs.build_artifact}} ${{matrix.configurations}}
path: ${{github.workspace}}/${{env.BUILD_PLATFORM}}/${{env.BUILD_CONFIGURATION}}
name: ${{inputs.build_artifact}}-${{matrix.configurations}}
path: ${{github.workspace}}/build-${{ matrix.configurations }}.zip
retention-days: 5
- name: Upload the MSI package (Debug)

11
.github/workflows/reusable-test.yml поставляемый
Просмотреть файл

@ -123,8 +123,15 @@ jobs:
uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
id: download_artifact
with:
name: ${{inputs.build_artifact}} ${{matrix.configurations}}
path: ${{github.workspace}}/${{env.BUILD_PLATFORM}}/${{env.BUILD_CONFIGURATION}}
name: ${{inputs.build_artifact}}-${{matrix.configurations}}
path: ${{github.workspace}}
- name: Extract build artifact
if: steps.skip_check.outputs.should_skip != 'true'
working-directory: ${{github.workspace}}
run: |
mkdir ${{env.BUILD_PLATFORM}}
Expand-Archive .\build-${{ matrix.configurations }}.zip -DestinationPath .\${{env.BUILD_PLATFORM}}
- name: Create generated artifact folder
if: (steps.skip_check.outputs.should_skip != 'true')