-
Notifications
You must be signed in to change notification settings - Fork 37
85 lines (67 loc) · 2.43 KB
/
jerigon.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: Jerigon Integration
on:
push:
branches: [develop, main]
pull_request:
branches:
- "**"
workflow_dispatch:
branches:
- "**"
env:
CARGO_TERM_COLOR: always
REGISTRY: ghcr.io
jobs:
test_jerigon_input_proving:
name: Test proof generation with jerigon input
runs-on: zero-ci
timeout-minutes: 40
if: "! contains(toJSON(github.event.commits.*.message), '[skip-ci]')"
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Checkout test-jerigon-network sources
uses: actions/checkout@v4
with:
repository: 0xPolygonZero/jerigon-test-network
path: test-jerigon-network
- name: Install nightly toolchain
uses: dtolnay/rust-toolchain@nightly
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up rust cache
uses: Swatinem/rust-cache@v2
with:
cache-on-failure: true
- name: Run jerigon test network with docker compose
run: |
cd test-jerigon-network
docker-compose -f docker-compose.yml up -d
docker logs -f smart-contracts
echo "Jerigon network is up and running, ready for testing"
- name: Rpc test with curl
run: |
curl -X POST -H "Content-Type: application/json" --data '{"jsonrpc": "2.0", "method": "eth_blockNumber", "params": [], "id":83}' localhost:8545
env:
RUST_LOG: info
- name: Run prove blocks in test_only mode
run: |
cd zero_bin/tools
OUTPUT_TO_TERMINAL=true ./prove_rpc.sh 0x2 0x3 http://localhost:8546 jerigon true 0 0 test_only
echo "Proving blocks in test_only mode finished"
- name: Run prove blocks in real mode
run: |
cd zero_bin/tools
rm -rf proofs/* circuits/* ./proofs.json test.out verify.out leader.out
OUTPUT_TO_TERMINAL=true RUN_VERIFICATION=true ./prove_rpc.sh 0x4 0x5 http://localhost:8546 jerigon true
echo "Proving blocks in real mode finished"
- name: Shut down network
run: |
cd test-jerigon-network
docker-compose -f docker-compose.yml down -v