Skip to content

workflow: move build operations in a reusable workflow #537

workflow: move build operations in a reusable workflow

workflow: move build operations in a reusable workflow #537

Workflow file for this run

name: bpf-ci
on:
pull_request:
push:
branches:
- bpf_base
- bpf-next_base
concurrency:
group: ci-test-${{ github.ref_name }}
cancel-in-progress: true
jobs:
set-matrix:
# FIXME: set-matrix is lightweight, run it on any self-hosted machines for kernel-patches org
# so we do not wait for GH hosted runners when there potentially all are busy because of bpf-rc
# repo for instance.
# This could be somehow fixed long term by making this action/workflow re-usable and letting the called
# specify what to run on.
runs-on: ${{ github.repository_owner == 'kernel-patches' && 'x86_64' || 'ubuntu-latest' }}
outputs:
build-matrix: ${{ steps.set-matrix-impl.outputs.build_matrix }}
test-matrix: ${{ steps.set-matrix-impl.outputs.test_matrix }}
veristat-runs-on: ${{ steps.set-matrix-impl.outputs.veristat_runs_on }}
steps:
- uses: actions/checkout@v3
- id: set-matrix-impl
run: |
python3 .github/scripts/matrix.py
# Build kernel and selftest
build:
uses: ./.github/workflows/kernel-build.yml
needs: set-matrix
strategy:
fail-fast: false
matrix: ${{ fromJSON(needs.set-matrix.outputs.build-matrix) }}
with:
arch: ${{ matrix.arch }}
toolchain_full: ${{ matrix.toolchain_full }}
toolchain: ${{ matrix.toolchain }}
runs_on: ${{ toJSON(matrix.runs_on) }}
llvm-version: ${{ matrix.llvm-version }}
kernel: ${{ matrix.kernel }}
test:
uses: ./.github/workflows/kernel-test.yml
needs: [set-matrix, build]
strategy:
fail-fast: false
matrix: ${{ fromJSON(needs.set-matrix.outputs.test-matrix) }}
with:
arch: ${{ matrix.arch }}
toolchain_full: ${{ matrix.toolchain_full }}
runs_on: ${{ toJSON(matrix.runs_on) }}
kernel: ${{ matrix.kernel }}
test: ${{ matrix.test }}
continue_on_error: ${{ matrix.continue_on_error }}
timeout_minutes: ${{ matrix.timeout_minutes }}
veristat:
uses: ./.github/workflows/kernel-veristat.yml

Check failure on line 63 in .github/workflows/test.yml

View workflow run for this annotation

GitHub Actions / bpf-ci

Invalid workflow file

The workflow is not valid. In .github/workflows/test.yml (Line: 63, Col: 11): Error from called workflow kernel-patches/vmtest/.github/workflows/kernel-veristat.yml@97e6aba2944699e5ea64e570db7cc575675ffe76 (Line: 16, Col: 9): Required property is missing: type
needs: [set-matrix, build]
with:
arch: x86_64
toolchain: gcc
aws_region: ${{ vars.AWS_REGION }}
secrets:
AWS_ROLE_ARN: ${{ secrets.AWS_ROLE_ARN }}