Skip to content

Commit

Permalink
Add support for workflow_dispatch
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelburnham committed Oct 18, 2024
1 parent ea78659 commit ccb9e44
Showing 1 changed file with 26 additions and 13 deletions.
39 changes: 26 additions & 13 deletions .github/workflows/plonk-artifacts.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,25 @@
name: Regenerate Plonk artifacts
# Generates and uploads new Plonk artifacts to S3 on every push to `dev` and manual release
# On `push`, the version/file name is the commit hash
# Use `workflow_dispatch` for Sphinx releases, with manually specified version name
name: Regenerate S3 Plonk artifacts

on:
push:
branches: dev
pull_request:
workflow_dispatch:
inputs:
version:
description: "Artifact version used for archive name, e.g. v1.0.0-testnet"
type: string
required: true

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
test:
name: CI Test Suite
:
name:
runs-on: warp-ubuntu-latest-x64-32x
steps:
- uses: actions/checkout@v4
Expand All @@ -23,6 +31,14 @@ jobs:
uses: ./.github/actions/setup
with:
pull_token: ${{ secrets.REPO_TOKEN }}
- name: Parse inputs
run: |
if [[ "${{ github.event_name }}" == "push" ]]; then
VERSION=$(git rev-parse --short HEAD)
else
VERSION=${{ inputs.version }}
fi
echo "VERSION=$VERSION" | tee -a $GITHUB_ENV
- name: Install AWS CLI
run: |
sudo apt-get update
Expand All @@ -33,13 +49,10 @@ jobs:
aws-access-key-id: ${{ secrets.S3_ACCESS_KEY }}
aws-secret-access-key: ${{ secrets.S3_SECRET_KEY }}
aws-region: us-east-2
- name: Test push to S3
- name: Generate Plonk artifacts
run: |
echo "Test file" > test-file2.txt
aws s3 cp "test-file2.txt" "s3://sphinx-plonk-params/test-file2.txt"
#- name: Generate Plonk artifacts
# run: |
# RUST_LOG=debug make build-plonk-bn254
# #echo "version" | make release-plonk-bn254
# echo "Finished building parameters"
# working-directory: ${{ github.workspace }}/prover
make build-plonk-bn254
working-directory: ${{ github.workspace }}/prover
- name: Release tarball on S3
echo "${{ env.VERSION }}" | make release-plonk-bn254
working-directory: ${{ github.workspace }}/prover

0 comments on commit ccb9e44

Please sign in to comment.