Skip to content

Commit

Permalink
Update 'build_upload_mithril_artifact' action
Browse files Browse the repository at this point in the history
Avoid unwanted usage of features when building the artifacts from the workspace.
Split in 2 phases: tooling first and then distribution.
  • Loading branch information
jpraynaud committed Dec 20, 2022
1 parent f54946b commit 16cf8fe
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ inputs:
build-args:
description: Arguments to pass to 'cargo build'
required: false
default: ''
default: '-p mithril-aggregator -p mithril-client -p mithril-common -p mithril-signer -p mithril-stm'
runs:
using: "composite"
steps:
Expand All @@ -14,10 +14,10 @@ runs:
pip3 install toml
python3 ./.github/workflows/scripts/edit-cargo-toml-version.py -l $(echo ${{ github.sha }} | cut -c1-7)
- name: Cargo build
- name: Cargo build - Distribution
shell: bash
run: cargo build --release ${{ inputs.build-args }}

- name: Publish Mithril Distribution (${{ runner.os }}-${{ runner.arch }})
uses: actions/upload-artifact@v3
with:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ jobs:
cache-version: ${{ secrets.CACHE_VERSION }}
cargo-tools: cargo-deb

# We separate the build in 2 steps as we want to avoid side effects with Rust feature unification.
- name: Cargo build - Tooling
shell: bash
run: cargo build --release --workspace --exclude mithril-aggregator --exclude mithril-client --exclude mithril-signer --exclude mithril-stm

- name: Build Mithril workspace & publish artifacts
uses: ./.github/workflows/actions/build-upload-mithril-artifact

Expand Down

0 comments on commit 16cf8fe

Please sign in to comment.