From 1521676ae39714f6d3efecea22195c54315599fa Mon Sep 17 00:00:00 2001 From: Milap Sheth Date: Fri, 16 Feb 2024 11:58:05 -0500 Subject: [PATCH] ci: use blacksmith runners for gh actions (#271) * ci: use blacksmith 16vcpu runners This change switches over the `basic` workflow to Blacksmith's 16vcpu runners. Additionally, this change switches the rust cache action to use the Blacksmith drop-in replacement. The Blacksmith version of the cache is colocated with Blacksmith runners and is substantially faster. The result is that this workflow is overall 2x faster and half the cost. * ci: move coverage to blacksmith 16vcpu runners * ci: remove `workflow_dispatch` from the triggers * ci: bump the `Test Suite` job to use 32vCPUs * ci: update `setup-protoc` step to avoid getting rate limited This commit adds an auth token to the `setup-protoc` step to avoid getting rate limited as per: https://github.com/arduino/setup-protoc?tab=readme-ov-file#usage. * ci: update `Test Suite` job to authenticate for `setup-protoc` This commit adds an auth token to the `setup-protoc` step to avoid getting rate limited as per: https://github.com/arduino/setup-protoc?tab=readme-ov-file#usage. * ci: move `Test Suite` job back to 16vCPUs * ci: move `Test Suite` and compilation steps to 32vCPU VMs --------- Co-authored-by: Aditya Maru Co-authored-by: Aayush Shah --- .github/workflows/basic.yaml | 14 ++++++++------ .github/workflows/codecov.yaml | 6 ++++-- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/basic.yaml b/.github/workflows/basic.yaml index 693601c99..330d4be48 100644 --- a/.github/workflows/basic.yaml +++ b/.github/workflows/basic.yaml @@ -12,7 +12,7 @@ name: Basic jobs: test: name: Test Suite - runs-on: ubuntu-8-core-32-gb + runs-on: blacksmith-32vcpu-ubuntu-2204 steps: - uses: actions/checkout@v4 @@ -25,9 +25,11 @@ jobs: - name: Install protoc uses: arduino/setup-protoc@v2 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Cache build artifacts - uses: Swatinem/rust-cache@v2 + uses: useblacksmith/rust-cache@v3 with: shared-key: "cache" @@ -42,7 +44,7 @@ jobs: cosmwasm-compilation: name: Cosmwasm Compilation - runs-on: ubuntu-8-core-32-gb + runs-on: blacksmith-32vcpu-ubuntu-2204 steps: - uses: actions/checkout@v4 @@ -55,7 +57,7 @@ jobs: override: true - name: Cache build artifacts - uses: Swatinem/rust-cache@v2 + uses: useblacksmith/rust-cache@v3 with: shared-key: "cache" @@ -78,7 +80,7 @@ jobs: lints: name: Lints - runs-on: ubuntu-8-core-32-gb + runs-on: blacksmith-16vcpu-ubuntu-2204 steps: - uses: actions/checkout@v4 @@ -96,7 +98,7 @@ jobs: repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Cache build artifacts - uses: Swatinem/rust-cache@v2 + uses: useblacksmith/rust-cache@v3 with: shared-key: "cache" diff --git a/.github/workflows/codecov.yaml b/.github/workflows/codecov.yaml index 30e2ec9ed..71b40b36e 100644 --- a/.github/workflows/codecov.yaml +++ b/.github/workflows/codecov.yaml @@ -9,7 +9,7 @@ on: jobs: coverage: - runs-on: ubuntu-8-core-32-gb + runs-on: blacksmith-16vcpu-ubuntu-2204 env: CARGO_TERM_COLOR: always steps: @@ -24,12 +24,14 @@ jobs: - name: Install protoc uses: arduino/setup-protoc@v2 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Install libclang-dev run: sudo apt-get install libclang-dev - name: Cache build artifacts - uses: Swatinem/rust-cache@v2 + uses: useblacksmith/rust-cache@v3 with: shared-key: "cache"