Merge pull request #52 from oasisprotocol/kostko/feature/prepare-3.1.… #144
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
# NOTE: This name appears in GitHub's Checks API and in workflow's status badge. | |
name: ci-test | |
# Trigger the workflow when: | |
on: | |
# A push occurs to one of the matched branches. | |
push: | |
branches: | |
- main | |
- stable/* | |
# Or when a pull request event occurs for a pull request against one of the | |
# matched branches. | |
pull_request: | |
branches: | |
- main | |
- stable/* | |
jobs: | |
test-rust: | |
# NOTE: This name appears in GitHub's Checks API. | |
name: test-rust | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./runtime | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Rust | |
run: rustup show | |
- name: Install protoc | |
run: sudo apt install -y protobuf-compiler | |
- name: Build | |
run: cargo build --release --locked | |
test-rust-sgx: | |
# NOTE: This name appears in GitHub's Checks API. | |
name: test-rust-sgx | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./runtime | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
# gcc-multilib is required for bindgen to work for SGX. | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install gcc-multilib | |
- name: Set up Rust | |
run: rustup show | |
- name: Check SGX buildability | |
run: cargo check --locked --release --target x86_64-fortanix-unknown-sgx |