Skip to content

Commit 37a6678

Browse files
johnsonjielispc
andauthored
add build releases workflow (#150)
* add build releases workflow * replace xxd to vim-common * Update build-guest-release.yml * update --------- Co-authored-by: Zhang Zhuo <[email protected]>
1 parent f3253c3 commit 37a6678

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
name: Build ZKVM-Prover Guest
2+
3+
on:
4+
push:
5+
tags:
6+
- **
7+
8+
jobs:
9+
build-guest:
10+
runs-on: ubuntu-latest
11+
env:
12+
SCROLL_ZKVM_VERSION: ${{ github.ref_name }}
13+
DIR_OUTPUT: releases/dev
14+
AWS_REGION: us-west-2
15+
16+
steps:
17+
- name: Checkout repository
18+
uses: actions/checkout@v4
19+
20+
- name: Install xxd
21+
run: sudo apt-get update && sudo apt-get install -y vim-common
22+
23+
- name: Install Rust nightly toolchain
24+
uses: actions-rs/toolchain@v1
25+
with:
26+
toolchain: 1.86
27+
target: x86_64-unknown-linux-gnu
28+
components: rust-src
29+
override: true
30+
31+
- name: Cache cargo registry and build
32+
uses: actions/cache@v4
33+
with:
34+
path: |
35+
~/.cargo/registry
36+
~/.cargo/git
37+
target
38+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
39+
40+
- name: Build guest binary
41+
run: make build-guest
42+
43+
- name: Prepare release
44+
run: |
45+
# checksum for assets
46+
find $DIR_OUTPUT -type f ! -name sha256sums.txt -exec sha256sum {} \; > $DIR_OUTPUT/sha256sums.txt
47+
48+
- id: install-aws-cli
49+
uses: unfor19/install-aws-cli-action@v1
50+
with:
51+
version: 2
52+
verbose: false
53+
arch: amd64
54+
55+
- name: Set up AWS credentials
56+
uses: aws-actions/configure-aws-credentials@v3
57+
with:
58+
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
59+
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
60+
aws-region: ${{ env.AWS_REGION }}
61+
62+
- name: Upload releases to S3
63+
run: |
64+
aws s3 cp $DIR_OUTPUT s3://circuit-release/scroll-zkvm/${{ github.ref_name }} --recursive

0 commit comments

Comments
 (0)