Skip to content

Commit

Permalink
CI: skip ARM build on PRs
Browse files Browse the repository at this point in the history
The arm uses buildjet and costs money. There is relatively little
utility in running it on every PR. If necessary it can be triggered
explicitly via workflow dispatch.
  • Loading branch information
sveitser committed Oct 29, 2024
1 parent 5c7841b commit f41d62f
Showing 1 changed file with 20 additions and 17 deletions.
37 changes: 20 additions & 17 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ concurrency:
env:
RUSTFLAGS: '--cfg async_executor_impl="async-std" --cfg async_channel_impl="async-std"'
RUST_LOG: info,libp2p=off,node=error
DOCKER_PLATFORMS: ${{ github.event_name == 'pull_request' && 'linux/amd64' || 'linux/amd64,linux/arm64' }}

jobs:
build:
Expand Down Expand Up @@ -86,6 +87,7 @@ jobs:
target/release/dev-rollup
build-arm:
if: github.event_name != 'pull_request'
runs-on: buildjet-16vcpu-ubuntu-2204-arm
steps:
- name: Fix submodule permissions check
Expand Down Expand Up @@ -174,6 +176,7 @@ jobs:
path: target/amd64/release

- name: Download executables ARM
if: github.event_name != 'pull_request'
uses: actions/download-artifact@v4
with:
name: aarch64-unknown-linux-gnu-services
Expand Down Expand Up @@ -298,7 +301,7 @@ jobs:
with:
context: ./
file: ./docker/sequencer.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.sequencer.outputs.tags }}
labels: ${{ steps.sequencer.outputs.labels }}
Expand All @@ -308,7 +311,7 @@ jobs:
with:
context: ./
file: ./docker/cdn-broker.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.cdn-broker.outputs.tags }}
labels: ${{ steps.cdn-broker.outputs.labels }}
Expand All @@ -318,7 +321,7 @@ jobs:
with:
context: ./
file: ./docker/cdn-marshal.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.cdn-marshal.outputs.tags }}
labels: ${{ steps.cdn-marshal.outputs.labels }}
Expand All @@ -328,7 +331,7 @@ jobs:
with:
context: ./
file: ./docker/cdn-whitelist.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.cdn-whitelist.outputs.tags }}
labels: ${{ steps.cdn-whitelist.outputs.labels }}
Expand All @@ -338,7 +341,7 @@ jobs:
with:
context: ./
file: ./docker/state-relay-server.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.state-relay-server.outputs.tags }}
labels: ${{ steps.state-relay-server.outputs.labels }}
Expand All @@ -348,7 +351,7 @@ jobs:
with:
context: ./
file: ./docker/prover-service.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.prover-service.outputs.tags }}
labels: ${{ steps.prover-service.outputs.labels }}
Expand All @@ -358,7 +361,7 @@ jobs:
with:
context: ./
file: ./docker/orchestrator.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.orchestrator.outputs.tags }}
labels: ${{ steps.orchestrator.outputs.labels }}
Expand All @@ -368,7 +371,7 @@ jobs:
with:
context: ./
file: ./docker/submit-transactions.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.submit-transactions.outputs.tags }}
labels: ${{ steps.submit-transactions.outputs.labels }}
Expand All @@ -378,7 +381,7 @@ jobs:
with:
context: ./
file: ./docker/deploy.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.deploy.outputs.tags }}
labels: ${{ steps.deploy.outputs.labels }}
Expand All @@ -388,7 +391,7 @@ jobs:
with:
context: ./
file: ./docker/permissionless-builder.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.builder.outputs.tags }}
labels: ${{ steps.builder.outputs.labels }}
Expand All @@ -398,7 +401,7 @@ jobs:
with:
context: ./
file: ./docker/nasty-client.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.nasty-client.outputs.tags }}
labels: ${{ steps.nasty-client.outputs.labels }}
Expand All @@ -408,7 +411,7 @@ jobs:
with:
context: ./
file: ./docker/espresso-dev-node.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.espresso-dev-node.outputs.tags }}
labels: ${{ steps.espresso-dev-node.outputs.labels }}
Expand All @@ -417,7 +420,7 @@ jobs:
with:
context: ./
file: ./docker/espresso-bridge.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.bridge.outputs.tags }}
labels: ${{ steps.bridge.outputs.labels }}
Expand All @@ -427,7 +430,7 @@ jobs:
with:
context: ./
file: ./docker/marketplace-solver.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.marketplace-solver.outputs.tags }}
labels: ${{ steps.marketplace-solver.outputs.labels }}
Expand All @@ -437,7 +440,7 @@ jobs:
with:
context: ./
file: ./docker/marketplace-builder.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.marketplace-builder.outputs.tags }}
labels: ${{ steps.marketplace-builder.outputs.labels }}
Expand All @@ -447,7 +450,7 @@ jobs:
with:
context: ./
file: ./docker/node-validator.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.node-validator.outputs.tags }}
labels: ${{ steps.node-validator.outputs.labels }}
Expand All @@ -457,7 +460,7 @@ jobs:
with:
context: ./
file: ./docker/dev-rollup.Dockerfile
platforms: linux/amd64,linux/arm64
platforms: ${{ env.DOCKER_PLATFORMS }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.dev-rollup.outputs.tags }}
labels: ${{ steps.dev-rollup.outputs.labels }}
Expand Down

0 comments on commit f41d62f

Please sign in to comment.