Skip to content

ci: test build job on multiple Ubuntu containers #56

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 17 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,24 +10,34 @@ on:

jobs:
check:
runs-on: ubuntu-22.04
strategy:
matrix:
image_ref: ['20.04', '22.04', '23.04', '23.10']
subcommand: ['fmt', 'build', 'clippy', 'test']
include:
- subcommand: 'clippy'
# treat warnings as errors
args: '-- -D warnings'
- subcommand: 'fmt'
args: '--check'
- subcommand: 'clippy'
# treat warnings as errors
args: '-- -D warnings'
- subcommand: 'fmt'
args: '--check'
- subcommand: 'build'

runs-on: ubuntu-latest
container:
image: ubuntu:${{ matrix.image_ref }}
steps:
- uses: actions/checkout@v4

- run: apt-get update && apt-get install -y curl build-essential clang

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: 'clippy,rustfmt'


- name: Install crate dependencies
run: sudo apt-get install -y libxen-dev
run: apt-get install -y libxen-dev

- run: cargo ${{ matrix.subcommand }} ${{ matrix.args }}

Expand Down