Skip to content

Ed/timeout

Ed/timeout #3721

Workflow file for this run

name: Build and Test Workflow
on:
push:
branches:
- 'benchmarking_*'
- 'main'
pull_request:
branches:
- 'main'
- '*/*'
schedule:
- cron: '0 0 * * 1'
workflow_dispatch:
jobs:
build:
strategy:
matrix:
just_variants:
- async_std
- tokio
runs-on: ubuntu-latest
steps:
- uses: styfle/[email protected]
name: Cancel Outdated Builds
with:
all_but_latest: true
access_token: ${{ github.token }}
- uses: actions/checkout@v4
name: Checkout Repository
- uses: Swatinem/rust-cache@v2
name: Enable Rust Caching
with:
shared-key: ""
prefix-key: ${{ matrix.just_variants }}
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y protobuf-compiler
cargo install just
- name: Build all crates in workspace
run: just ${{ matrix.just_variants }} build
- name: Unit and integration tests for all crates in workspace
run: |
just ${{ matrix.just_variants }} test
timeout-minutes: 60
env:
RUST_BACKTRACE: full
# - name: Setup Docker BuildKit (buildx)
# if: matrix.just_variants == 'async_std'
# uses: docker/setup-buildx-action@v3
# - name: Login to Github Container Repo
# uses: docker/login-action@v3
# if: github.event_name != 'pull_request' && matrix.just_variants == 'async_std'
# with:
# registry: ghcr.io
# username: ${{ github.repository_owner }}
# password: ${{ secrets.GITHUB_TOKEN }}
# - name: Generate docker metadata (web-server)
# uses: docker/metadata-action@v5
# if: matrix.just_variants == 'async_std'
# id: web-server
# with:
# images: ghcr.io/espressosystems/hotshot/web-server
# - name: Build and push web-server docker
# uses: docker/build-push-action@v5
# if: matrix.just_variants == 'async_std'
# with:
# context: ./
# file: ./deploy/web-server.Dockerfile
# platforms: linux/amd64
# push: ${{ github.event_name != 'pull_request' }}
# tags: ${{ steps.web-server.outputs.tags }}
# labels: ${{ steps.web-server.outputs.labels }}