Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: add workflows to Nightly Dispatcher #2188

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 33 additions & 5 deletions .github/workflows/aggregator-stress-test.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Aggregator stress test

on:
workflow_call:
workflow_dispatch:
inputs:
commit_sha:
Expand All @@ -24,8 +25,33 @@ on:
default: false

jobs:
prepare:
runs-on: ubuntu-22.04
outputs:
branch: ${{ steps.set-env.outputs.branch }}
commit_sha: ${{ steps.set-env.outputs.commit_sha }}
num_signers: ${{ steps.set-env.outputs.num_signers }}
num_clients: ${{ steps.set-env.outputs.num_clients }}
enable_debug: ${{ steps.set-env.outputs.enable_debug }}
steps:
- name: Prepare env variables
id: set-env
shell: bash
run: |
if [[ "${{ github.event_name }}" == "schedule" ]]; then
echo "branch=main" >> $GITHUB_OUTPUT
echo "num_signers=100" >> $GITHUB_OUTPUT
echo "num_clients=100" >> $GITHUB_OUTPUT
echo "enable_debug=false" >> $GITHUB_OUTPUT
else
echo "commit_sha=${{ inputs.commit_sha }}" >> $GITHUB_OUTPUT
echo "num_signers=${{ inputs.num_signers }}" >> $GITHUB_OUTPUT
echo "num_clients=${{ inputs.num_clients }}" >> $GITHUB_OUTPUT
echo "enable_debug=${{ inputs.enable_debug }}"s >> $GITHUB_OUTPUT
fi
stress-test:
runs-on: ubuntu-22.04
needs: [prepare]
steps:
- name: Checkout sources
uses: actions/checkout@v4
Expand All @@ -34,7 +60,7 @@ jobs:
id: prepare
shell: bash
run: |
if [[ "${{ inputs.enable_debug }}" == "true" ]]; then
if [[ "${{ needs.prepare.outputs.enable_debug }}" == "true" ]]; then
echo "debug_level=-vvv" >> $GITHUB_OUTPUT
fi

Expand All @@ -48,7 +74,8 @@ jobs:
with:
name: mithril-distribution-Linux-X64
path: ./bin
commit: ${{ inputs.commit_sha }}
commit: ${{ needs.prepare.outputs.commit_sha }}
branch: ${{ needs.prepare.outputs.branch }}
workflow: ci.yml
workflow_conclusion: success

Expand All @@ -57,7 +84,8 @@ jobs:
with:
name: mithril-tooling-Linux-X64
path: ./bin
commit: ${{ inputs.commit_sha }}
commit: ${{ needs.prepare.outputs.commit_sha }}
branch: ${{ needs.prepare.outputs.branch }}
workflow: ci.yml
workflow_conclusion: success

Expand All @@ -73,5 +101,5 @@ jobs:
./bin/load-aggregator ${{ steps.prepare.outputs.debug_level }} \
--cardano-cli-path ./mithril-test-lab/mithril-end-to-end/script/mock-cardano-cli \
--aggregator-dir ./bin \
--num-signers=${{ inputs.num_signers }} \
--num-clients=${{ inputs.num_clients }}
--num-signers=${{ needs.prepare.outputs.num_signers }} \
--num-clients=${{ needs.prepare.outputs.num_clients }}
9 changes: 6 additions & 3 deletions .github/workflows/nightly-dispatcher.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,18 @@ on:
- cron: "0 2 * * *"

jobs:
backward-compatibility:
uses: ./.github/workflows/backward-compatibility.yml

docker-builds:
uses: ./.github/workflows/docker-builds.yml

backward-compatibility:
uses: ./.github/workflows/backward-compatibility.yml
aggregator-stress-test:
uses: ./.github/workflows/aggregator-stress-test.yml

notify-on-failure:
runs-on: ubuntu-22.04
needs: [docker-builds]
needs: [docker-builds, aggregator-stress-test]
if: failure()
steps:
- name: Checkout repository
Expand Down