Skip to content

Commit

Permalink
kernel-build: use libbpf/ci/tar-artifacts action (#298)
Browse files Browse the repository at this point in the history
  • Loading branch information
theihor authored Oct 24, 2024
1 parent 0c55506 commit dba1041
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 116 deletions.
107 changes: 0 additions & 107 deletions .github/scripts/tar-artifact.sh

This file was deleted.

26 changes: 17 additions & 9 deletions .github/workflows/kernel-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,17 +45,17 @@ jobs:
runs-on: ${{ fromJSON(inputs.runs_on) }}
timeout-minutes: 100
env:
ARCHIVE_MAKE_HELPERS: ${{ github.repository != 'kernel-patches/bpf' && 'true' || '' }}
KERNEL: ${{ inputs.kernel }}
REPO_ROOT: ${{ github.workspace }}
REPO_PATH: ""
KBUILD_OUTPUT: ${{ github.workspace }}/kbuild-output
ARTIFACTS_ARCHIVE: "vmlinux-${{ inputs.arch }}-${{ inputs.toolchain_full }}.tar.zst"
BASE_BRANCH: >-
${{ github.event_name == 'push' && github.ref_name
|| github.base_ref
|| 'bpf-next'
}}
BUILD_SCHED_EXT_SELFTESTS: ${{ inputs.arch == 'x86_64' || inputs.arch == 'aarch64' && 'true' || '' }}
KBUILD_OUTPUT: ${{ github.workspace }}/kbuild-output
KERNEL: ${{ inputs.kernel }}
REPO_PATH: ""
REPO_ROOT: ${{ github.workspace }}
steps:
- uses: actions/checkout@v4
# We fetch an actual bit of history here to facilitate incremental
Expand Down Expand Up @@ -140,9 +140,17 @@ jobs:
max-make-jobs: 32
llvm-version: ${{ inputs.llvm-version }}
- name: Tar artifacts
working-directory: ${{ env.REPO_ROOT }}
run: |
bash .github/scripts/tar-artifact.sh ${{ inputs.arch }} ${{ inputs.toolchain_full }}
id: tar-artifacts
uses: libbpf/ci/tar-artifacts@v1
env:
ARCHIVE_BPF_SELFTESTS: 'true'
ARCHIVE_MAKE_HELPERS: ${{ github.repository != 'kernel-patches/bpf' && 'true' || '' }}
ARCHIVE_SCHED_EXT_SELFTESTS: ${{ env.BUILD_SCHED_EXT_SELFTESTS }}
with:
arch: ${{ inputs.arch }}
archive: ${{ env.ARTIFACTS_ARCHIVE }}
kbuild-output: ${{ env.KBUILD_OUTPUT }}
repo-root: ${{ env.REPO_ROOT }}
- if: ${{ github.event_name != 'push' }}
name: Remove KBUILD_OUTPUT content
shell: bash
Expand All @@ -155,4 +163,4 @@ jobs:
with:
name: vmlinux-${{ inputs.arch }}-${{ inputs.toolchain_full }}${{ inputs.release && '-release' || '' }}
if-no-files-found: error
path: vmlinux-${{ inputs.arch }}-${{ inputs.toolchain_full }}.tar.zst
path: ${{ env.ARTIFACTS_ARCHIVE }}

0 comments on commit dba1041

Please sign in to comment.