-
Notifications
You must be signed in to change notification settings - Fork 287
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ddafe0e
commit 08b067f
Showing
4 changed files
with
95 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,13 +8,11 @@ on: | |
|
||
jobs: | ||
lint: | ||
name: Lint | ||
name: Lint (${{ matrix.target_arch }}) | ||
runs-on: ubuntu-24.04 | ||
strategy: | ||
fail-fast: true | ||
max-parallel: 2 | ||
matrix: | ||
go: ["stable"] | ||
target_arch: [amd64, arm64] | ||
steps: | ||
- name: Clone code | ||
uses: actions/checkout@v4 | ||
|
@@ -26,79 +24,94 @@ jobs: | |
make lint | ||
test: | ||
name: Test | ||
name: Test (${{ matrix.target_arch }}) | ||
runs-on: ubuntu-24.04 | ||
strategy: | ||
fail-fast: true | ||
max-parallel: 2 | ||
matrix: | ||
go: ["stable"] | ||
target_arch: [amd64, arm64] | ||
steps: | ||
- name: Clone code | ||
uses: actions/checkout@v4 | ||
- name: Set up environment | ||
uses: ./.github/workflows/env | ||
- name: Build | ||
run: | | ||
echo $PATH | ||
make test | ||
- name: Tests | ||
run: | | ||
make test | ||
run: make test TARGET_ARCH=${{ matrix.target_arch }} | ||
|
||
build-integration-test-binaries: | ||
name: Build integration test binaries | ||
name: Build integration test binaries (${{ matrix.target_arch }}) | ||
runs-on: ubuntu-24.04 | ||
timeout-minutes: 10 | ||
strategy: | ||
matrix: | ||
target_arch: [amd64, arm64] | ||
steps: | ||
- name: Clone code | ||
uses: actions/checkout@v4 | ||
- name: Set up environment | ||
uses: ./.github/workflows/env | ||
- name: Prepare integration test binaries for qemu tests | ||
run: | | ||
make integration-test-binaries | ||
run: make integration-test-binaries TARGET_ARCH=${{ matrix.target_arch }} | ||
- name: Upload integration test binaries | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: integration-test-binaries | ||
name: integration-test-binaries-${{ matrix.target_arch }} | ||
path: support/*.test | ||
|
||
integration-tests: | ||
name: Integration tests (kernel v${{ matrix.kernel-version }}) | ||
name: Integration tests (v${{ matrix.kernel }} ${{ matrix.target_arch }}) | ||
runs-on: ubuntu-24.04 | ||
needs: build-integration-test-binaries | ||
timeout-minutes: 10 | ||
strategy: | ||
matrix: | ||
kernel-version: | ||
- "4.19.314" | ||
- "5.4.276" | ||
- "5.10.217" | ||
- "5.15.159" | ||
- "6.1.91" | ||
- "6.6.31" | ||
- "6.8.10" | ||
- "6.9.1" | ||
include: | ||
# List of available kernels here: | ||
# https://github.com/cilium/ci-kernels/pkgs/container/ci-kernels/versions?filters%5Bversion_type%5D=tagged | ||
|
||
# AMD64 | ||
- { target_arch: amd64, kernel: 4.19.314 } | ||
- { target_arch: amd64, kernel: 5.4.276 } | ||
- { target_arch: amd64, kernel: 5.10.217 } | ||
- { target_arch: amd64, kernel: 5.15.159 } | ||
- { target_arch: amd64, kernel: 6.1.91 } | ||
- { target_arch: amd64, kernel: 6.6.31 } | ||
- { target_arch: amd64, kernel: 6.8.10 } | ||
- { target_arch: amd64, kernel: 6.9.1 } | ||
|
||
# ARM64 (NOTE: older ARM64 kernels are not available in Cilium repos) | ||
- { target_arch: arm64, kernel: 6.6.31 } | ||
- { target_arch: arm64, kernel: 6.8.4 } | ||
- { target_arch: arm64, kernel: 6.9.1 } | ||
steps: | ||
- name: Clone code | ||
uses: actions/checkout@v4 | ||
- name: Set up environment | ||
uses: ./.github/workflows/env | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get -y install qemu-system-x86 | ||
case "${{ matrix.target_arch }}" in | ||
amd64) sudo apt-get -y install qemu-system-x86;; | ||
arm64) sudo apt-get -y install qemu-system-arm;; | ||
*) echo >&2 "bug: bad arch selected"; exit 1;; | ||
esac | ||
go install github.com/florianl/[email protected] | ||
sudo mv ~/go/bin/bluebox /usr/local/bin/. | ||
- name: Fetch integration test binaries | ||
uses: actions/download-artifact@v4 | ||
with: { name: integration-test-binaries } | ||
- name: Fetch precompiled kernels | ||
with: { name: "integration-test-binaries-${{ matrix.target_arch }}" } | ||
- name: Fetch precompiled kernel | ||
run: | | ||
install -d ci-kernels | ||
echo "FROM ghcr.io/cilium/ci-kernels:${{ matrix.kernel-version }}" \ | ||
| docker buildx build --quiet --pull --output="ci-kernels" - | ||
mv ci-kernels/boot/ ci-kernels/${{ matrix.kernel-version }}/ | ||
- name: Test on kernel ${{ matrix.kernel-version }} | ||
echo "FROM ghcr.io/cilium/ci-kernels:${{ matrix.kernel }}" \ | ||
| docker buildx build --platform linux/${{ matrix.target_arch }} \ | ||
--quiet --pull --output="ci-kernels" - | ||
mv ci-kernels/boot/ ci-kernels/${{ matrix.kernel }}/ | ||
- name: Test on kernel ${{ matrix.kernel }} | ||
run: | | ||
chmod a+rx *.test | ||
support/run-tests.sh ${{ matrix.kernel-version }} | ||
case "${{ matrix.target_arch }}" in | ||
amd64) export QEMU_ARCH=x86_64;; | ||
arm64) export QEMU_ARCH=aarch64;; | ||
*) echo >&2 "bug: bad arch selected"; exit 1;; | ||
esac | ||
support/run-tests.sh ${{ matrix.kernel }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters