mirror of https://github.com/aya-rs/aya
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
1.5 KiB
YAML
70 lines
1.5 KiB
YAML
name: Build aya
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
- ci
|
|
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: Swatinem/rust-cache@v1
|
|
|
|
- name: Build
|
|
run: cargo build --verbose
|
|
|
|
- name: Run tests
|
|
run: RUST_BACKTRACE=full cargo test --verbose
|
|
|
|
test:
|
|
runs-on: ubuntu-20.04
|
|
needs: build
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: nightly
|
|
components: rustfmt, clippy, rust-src
|
|
override: true
|
|
target: x86_64-unknown-linux-musl
|
|
|
|
- uses: Swatinem/rust-cache@v1
|
|
|
|
- name: Set up Go 1.17
|
|
uses: actions/setup-go@v2
|
|
with:
|
|
go-version: 1.17
|
|
|
|
- name: Set GOPATH
|
|
run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
|
|
env:
|
|
GOPATH: ${{runner.workspace}}
|
|
|
|
- name: Install prereqs
|
|
run: |
|
|
go install github.com/linuxkit/rtf@latest
|
|
cargo install bpf-linker
|
|
cargo install rust-script
|
|
cargo install sccache
|
|
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
|
|
export DEBIAN_FRONTEND=noninteractive
|
|
sudo apt-get update
|
|
sudo apt-get install -qy qemu-utils qemu-system-x86 cloud-image-utils genisoimage
|
|
|
|
- name: Run regression tests
|
|
run: |
|
|
cd test
|
|
rtf -vvv run |