Skip to content

Commit f102d18

Browse files
committed
fix: address comments
1 parent b221d42 commit f102d18

File tree

8 files changed

+13
-108
lines changed

8 files changed

+13
-108
lines changed

permissionless-batches/Makefile

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
1-
.PHONY: batch-production-submission launch_local_prover launch_cloud_prover psql check_proving_status
1+
.PHONY: batch_production_submission launch_prover psql check_proving_status
22

3-
export SCROLL_ZKVM_VERSION=0.3.0
3+
export SCROLL_ZKVM_VERSION=0.4.2
44
PG_URL=postgres://postgres@localhost:5432/scroll
55

66
batch_production_submission:
77
docker compose --profile batch-production-submission up
88

9-
local_prover:
10-
docker compose --profile local-prover up -d
11-
12-
cloud_prover:
13-
docker compose --profile cloud-prover up
9+
launch_prover:
10+
docker compose up -d
1411

1512
psql:
1613
psql 'postgres://postgres@localhost:5432/scroll'

permissionless-batches/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,16 +94,16 @@ This will produce chunks, a batch and bundle which will be proven in the next st
9494
`Success! You're ready to generate proofs!` indicates that everything is working correctly and the batch is ready to be proven.
9595

9696
#### Proving a batch
97-
To prove the chunk, batch and bundle you just generated you need to run the `local-prover` or `cloud-prover` profile in `docker-compose.yml`.
97+
To prove the chunk, batch and bundle you just generated you need to run the `prover` profile in `docker-compose.yml`.
9898

9999
Local Proving:
100100

101101
1. Hardware spec for local prover: CPU: 36+ core, 128G memory GPU: 24G memory (e.g. Rtx 3090/3090Ti/4090/A10/L4)
102102
2. Make sure `verifier` and `high_version_circuit` in `conf/coordinator/config.json` are correct for the latest fork: [TODO link list with versions](#batch-production-toolkit)
103103
2. Set the `SCROLL_ZKVM_VERSION` environment variable on `Makefile` to the correct version. [TODO link list with versions](#batch-production-toolkit)
104-
4. Fill in the required fields in `conf/proving-service/local-prover/config.json`
104+
4. Fill in the required fields in `conf/proving-service/config.json`
105105

106-
Run with `make local_prover`.
106+
Run with `make launch_prover`.
107107

108108

109109
#### Batch submission

permissionless-batches/conf/coordinator/coordinator_run.sh

Lines changed: 0 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -35,69 +35,18 @@ BASE_DOWNLOAD_DIR="/verifier"
3535
mkdir -p "$BASE_DOWNLOAD_DIR"
3636

3737
# Set subdirectories
38-
ASSETS_DIR="$BASE_DOWNLOAD_DIR/assets"
3938
OPENVM_DIR="$BASE_DOWNLOAD_DIR/openvm"
4039

4140
# Create necessary directories
42-
mkdir -p "$ASSETS_DIR"
4341
mkdir -p "$OPENVM_DIR/verifier"
4442

45-
# Define URLs for asset files
46-
ASSETS_CHECKSUM_URL="https://circuit-release.s3.us-west-2.amazonaws.com/release-v0.13.1/sha256sum"
47-
ASSETS_CHECKSUM_FILE="$ASSETS_DIR/sha256sum"
48-
49-
ASSETS_URLS=(
50-
"https://circuit-release.s3.us-west-2.amazonaws.com/release-v0.13.1/vk_batch.vkey"
51-
"https://circuit-release.s3.us-west-2.amazonaws.com/release-v0.13.1/vk_bundle.vkey"
52-
"https://circuit-release.s3.us-west-2.amazonaws.com/release-v0.13.1/vk_chunk.vkey"
53-
)
54-
5543
# Define URLs for OpenVM files (No checksum verification)
5644
OPENVM_URLS=(
5745
"https://circuit-release.s3.us-west-2.amazonaws.com/scroll-zkvm/releases/$SCROLL_ZKVM_VERSION/verifier/verifier.bin"
5846
"https://circuit-release.s3.us-west-2.amazonaws.com/scroll-zkvm/releases/$SCROLL_ZKVM_VERSION/verifier/root-verifier-vm-config"
5947
"https://circuit-release.s3.us-west-2.amazonaws.com/scroll-zkvm/releases/$SCROLL_ZKVM_VERSION/verifier/root-verifier-committed-exe"
6048
)
6149

62-
# Function to download and verify files (skips existing valid files)
63-
download_and_verify() {
64-
local url="$1"
65-
local dest_dir="$2"
66-
local checksum_file="$3"
67-
68-
local filename=$(basename "$url")
69-
local filepath="$dest_dir/$filename"
70-
71-
if [[ -f "$filepath" ]]; then
72-
echo "Checking existing file: $filename..."
73-
if grep "$filename" "$checksum_file" | sed "s|$filename|$filepath|" | sha256sum --check --status; then
74-
echo "File is already present and valid ✅ - Skipping download."
75-
return
76-
else
77-
echo "File exists but checksum mismatch ❌ - Re-downloading."
78-
rm -f "$filepath"
79-
fi
80-
fi
81-
82-
echo "Downloading $filename..."
83-
curl -o "$filepath" -L "$url"
84-
85-
if [[ ! -f "$filepath" ]]; then
86-
echo "Download failed for $filename"
87-
exit 1
88-
fi
89-
90-
echo "Verifying checksum for $filename..."
91-
grep "$filename" "$checksum_file" | sed "s|$filename|$filepath|" | sha256sum --check --status || exit 1
92-
echo "Checksum verification passed for $filename"
93-
}
94-
95-
# Download and verify asset files
96-
curl -o "$ASSETS_CHECKSUM_FILE" -L "$ASSETS_CHECKSUM_URL"
97-
for url in "${ASSETS_URLS[@]}"; do
98-
download_and_verify "$url" "$ASSETS_DIR" "$ASSETS_CHECKSUM_FILE"
99-
done
100-
10150
# Download OpenVM files (No checksum verification, but skips if file exists)
10251
for url in "${OPENVM_URLS[@]}"; do
10352
dest_subdir="$OPENVM_DIR/$(basename $(dirname "$url"))"

permissionless-batches/conf/proving-service/cloud-prover/.gitkeep

Whitespace-only changes.

permissionless-batches/conf/proving-service/cloud-prover/config.json

Lines changed: 0 additions & 23 deletions
This file was deleted.
File renamed without changes.

permissionless-batches/conf/proving-service/local-prover/prover_run.sh renamed to permissionless-batches/conf/proving-service/prover_run.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,3 @@ chmod +x /usr/local/bin/solc
5252
mkdir -p /openvm/cache
5353

5454
RUST_MIN_STACK=16777216 RUST_BACKTRACE=1 exec /prover/prover --config /prover/conf/config.json
55-

permissionless-batches/docker-compose.yml

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ services:
3434
- "5432:5432"
3535

3636
coordinator-api:
37-
image: scrolltech/coordinator-api:v4.5.7
37+
image: scrolltech/coordinator-api:v4.5.19
3838
volumes:
3939
- ./conf/coordinator/config.json:/coordinator/config.json:ro
4040
- ./conf/genesis.json:/coordinator/genesis.json:ro
@@ -74,39 +74,22 @@ services:
7474
condition: service_healthy
7575

7676
local-prover:
77-
image: scrolltech/cuda-prover:v4.5.7-a18fe064-fcc09d1-9174aff
77+
image: scrolltech/cuda-prover:v4.5.12-97de9882-6ad5d8c-261b322
7878
network_mode: host
7979
platform: linux/amd64
8080
runtime: nvidia
8181
entrypoint: /bin/prover_run.sh
82-
profiles:
83-
- local-prover
8482
environment:
8583
- SCROLL_ZKVM_VERSION=${SCROLL_ZKVM_VERSION}
8684
- LD_LIBRARY_PATH=/prover:/usr/local/cuda/lib64
8785
- RUST_MIN_STACK=16777216
8886
- RUST_BACKTRACE=1
8987
- RUST_LOG=info
9088
volumes:
91-
- ./conf/proving-service/local-prover/config.json:/prover/conf/config.json:ro
92-
- ./conf/proving-service/local-prover/prover_run.sh:/bin/prover_run.sh
93-
- ./conf/proving-service/local-prover/db:/db
94-
- ./conf/proving-service/local-prover/keys:/keys
95-
depends_on:
96-
coordinator-api:
97-
condition: service_healthy
98-
99-
cloud-prover:
100-
image: scrolltech/sdk-cloud-prover:sindri-v0.0.5
101-
platform: linux/amd64
102-
command: "--config /app/config.json"
103-
profiles:
104-
- cloud-prover
105-
environment:
106-
- N_WORKERS=1
107-
volumes:
108-
- ./conf/proving-service/chunk/:/app/
109-
- ./conf/proving-service/config.json:/app/config.json
89+
- ./conf/proving-service/config.json:/prover/conf/config.json:ro
90+
- ./conf/proving-service/prover_run.sh:/bin/prover_run.sh
91+
- ./conf/proving-service/db:/db
92+
- ./conf/proving-service/keys:/keys
11093
depends_on:
11194
coordinator-api:
11295
condition: service_healthy

0 commit comments

Comments
 (0)