From e891433cbec103c4acd265b6ee4e409088171adb Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Thu, 28 Nov 2024 21:08:27 +1100 Subject: [PATCH 01/13] feat: add multiprover configs --- .env.sample | 2 +- docker-compose.yml | 68 ++++++++++++++++++++++++++++++++++++++++------ 2 files changed, 61 insertions(+), 9 deletions(-) diff --git a/.env.sample b/.env.sample index 79811ae..df4b7ee 100644 --- a/.env.sample +++ b/.env.sample @@ -10,7 +10,7 @@ PORT_GRAFANA=3001 BOOT_NODES= # Taiko protocol contract addresses -TAIKO_L1_ADDRESS=0xaE37C7A711bcab9B0f8655a97B738d6ccaB6560B +TAIKO_L1_ADDRESS=0x3c0e871bB7337D5e6A18FDD73c4D9e7567961Ad3 TAIKO_L2_ADDRESS=0x7633740000000000000000000000000000010001 # P2P diff --git a/docker-compose.yml b/docker-compose.yml index 9e0cf5d..383bcb8 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,11 +1,11 @@ services: nethermind_execution_l2: - image: nethermindeth/nethermind:surge-2b6ed5201 + image: nethermindeth/nethermind:surge-177139a04 + container_name: l2-nethermind-execution-client restart: unless-stopped pull_policy: always stop_grace_period: 3m tty: true - container_name: execution-taiko-l2-client volumes: - ./jwtsecret:/tmp/jwt/jwtsecret - ./chainspec.json:/chainspec.json @@ -51,10 +51,12 @@ services: profiles: - nethermind_execution_l2 - proposer + - prover - blockscout taiko_client_driver: image: nethsurge/taiko-client:f042ca8 + container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always depends_on: @@ -69,19 +71,21 @@ services: command: - driver - --l1.ws=${L1_ENDPOINT_WS} - - --l2.ws=ws://execution-taiko-l2-client:8548 + - --l2.ws=ws://l2-nethermind-execution-client:8548 - --l1.beacon=${L1_BEACON_HTTP} - - --l2.auth=http://execution-taiko-l2-client:8552 + - --l2.auth=http://l2-nethermind-execution-client:8552 - --taikoL1=${TAIKO_L1_ADDRESS} - --taikoL2=${TAIKO_L2_ADDRESS} - --jwtSecret=/tmp/jwt/jwtsecret profiles: - nethermind_execution_l2 - proposer + - prover - blockscout taiko_client_proposer: image: nethsurge/taiko-client:f042ca8 + container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always depends_on: @@ -97,8 +101,8 @@ services: command: - proposer - --l1.ws=${L1_ENDPOINT_WS} - - --l2.http=http://execution-taiko-l2-client:8547 - - --l2.auth=http://execution-taiko-l2-client:8552 + - --l2.http=http://l2-nethermind-execution-client:8547 + - --l2.auth=http://l2-nethermind-execution-client:8552 - --taikoL1=${TAIKO_L1_ADDRESS} - --taikoL2=${TAIKO_L2_ADDRESS} - --jwtSecret=/tmp/jwt/jwtsecret @@ -131,6 +135,54 @@ services: # - --tx.sendTimeout ${TX_SEND_TIMEOUT} profiles: - proposer + - prover + - blockscout + + taiko_client_prover_relayer: + image: nethsurge/taiko-client:f042ca8 + container_name: l2-taiko-prover-relayer-client + restart: unless-stopped + pull_policy: always + depends_on: + - nethermind_execution_l2 + - taiko_client_driver + networks: + - surge + entrypoint: + - taiko-client + command: + - prover + - --l1.ws=${L1_ENDPOINT_WS} + - --l2.ws=ws://l2-nethermind-execution-client:8548 + - --l2.http=http://l2-nethermind-execution-client:8547 + - --taikoL1=${TAIKO_L1_ADDRESS} + - --taikoL2=${TAIKO_L2_ADDRESS} + - --l1.proverPrivKey=${L1_PROPOSER_PRIVATE_KEY} + - --prover.capacity=${PROVER_CAPACITY} + - --tx.notInMempoolTimeout=30s + - --tx.resubmissionTimeout=10s + - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} + - --raiko.host=${SGX_RAIKO_HOST} + - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} + # conditioned + # - --proverSet ${PROVER_SET} + # - --prover.allowance ${TOKEN_ALLOWANCE} + # - --prover.minEthBalance ${MIN_ETH_BALANCE} + # - --prover.minTaikoTokenBalance ${MIN_TAIKO_BALANCE} + # - --prover.proveUnassignedBlocks + # - --tx.feeLimitMultiplier ${TX_FEE_LIMIT_MULTIPLIER} + # - --tx.feeLimitThreshold ${TX_FEE_LIMIT_THRESHOLD} + # - --tx.gasLimit ${TX_GAS_LIMIT} + # - --tx.minBaseFee ${TX_MIN_BASEFEE} + # - --tx.minTipCap ${TX_MIN_TIP_CAP} + # - --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL} + # - --tx.numConfirmations ${TX_NUM_CONFIRMATIONS} + # - --tx.receiptQueryInterval ${TX_RECEIPT_QUERY} + # - --tx.resubmissionTimeout ${TX_RESUBMISSION} + # - --tx.safeAbortNonceTooLowCount ${TX_SAFE_ABORT_NONCE_TOO_LOW} + # - --tx.sendTimeout ${TX_SEND_TIMEOUT} + profiles: + - prover - blockscout taiko-blockscout-postgres: @@ -202,10 +254,10 @@ services: API_V2_ENABLED: true ETHEREUM_JSONRPC_VARIANT: nethermind MICROSERVICE_SC_VERIFIER_URL: http://taiko-blockscout-verif:8050/api - ETHEREUM_JSONRPC_HTTP_URL: http://execution-taiko-l2-client:8547/ + ETHEREUM_JSONRPC_HTTP_URL: http://l2-nethermind-execution-client:8547/ INDEXER_DISABLE_PENDING_TRANSACTIONS_FETCHER: true SUBNETWORK: Kurtosis - ETHEREUM_JSONRPC_TRACE_URL: http://execution-taiko-l2-client:8547/ + ETHEREUM_JSONRPC_TRACE_URL: http://l2-nethermind-execution-client:8547/ COIN: ETH MICROSERVICE_SC_VERIFIER_TYPE: sc_verifier PORT: 4000 From 747742c18fd5f96ed814209adf945767ef265465 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Fri, 29 Nov 2024 21:58:02 +1100 Subject: [PATCH 02/13] feat: update taiko client image --- docker-compose.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 383bcb8..a104390 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -55,7 +55,7 @@ services: - blockscout taiko_client_driver: - image: nethsurge/taiko-client:f042ca8 + image: nethsurge/taiko-client:multiprover container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always @@ -84,7 +84,7 @@ services: - blockscout taiko_client_proposer: - image: nethsurge/taiko-client:f042ca8 + image: nethsurge/taiko-client:multiprover container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always @@ -139,7 +139,7 @@ services: - blockscout taiko_client_prover_relayer: - image: nethsurge/taiko-client:f042ca8 + image: nethsurge/taiko-client:multiprover container_name: l2-taiko-prover-relayer-client restart: unless-stopped pull_policy: always From 054e248c88fa260ea7a94630d87666b9c0d84526 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Sat, 30 Nov 2024 00:35:03 +1100 Subject: [PATCH 03/13] debug: update taiko client image without taikoToken --- docker-compose.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index a104390..4a65582 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -55,7 +55,7 @@ services: - blockscout taiko_client_driver: - image: nethsurge/taiko-client:multiprover + image: nethsurge/taiko-client:mptest container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always @@ -84,7 +84,7 @@ services: - blockscout taiko_client_proposer: - image: nethsurge/taiko-client:multiprover + image: nethsurge/taiko-client:mptest container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always @@ -139,7 +139,7 @@ services: - blockscout taiko_client_prover_relayer: - image: nethsurge/taiko-client:multiprover + image: nethsurge/taiko-client:mptest container_name: l2-taiko-prover-relayer-client restart: unless-stopped pull_policy: always From 0e2821f08fe08a76ce99ee5e0ebe5fd64eceab87 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Fri, 6 Dec 2024 19:33:33 +1100 Subject: [PATCH 04/13] feat: add l2 protocol deployment to docker compose and update env vars --- .env.sample | 11 +++++++---- docker-compose.yml | 46 +++++++++++++++++++++++++++++++++++++++++++--- 2 files changed, 50 insertions(+), 7 deletions(-) diff --git a/.env.sample b/.env.sample index df4b7ee..6eeb518 100644 --- a/.env.sample +++ b/.env.sample @@ -10,7 +10,7 @@ PORT_GRAFANA=3001 BOOT_NODES= # Taiko protocol contract addresses -TAIKO_L1_ADDRESS=0x3c0e871bB7337D5e6A18FDD73c4D9e7567961Ad3 +TAIKO_L1_ADDRESS=0xaE37C7A711bcab9B0f8655a97B738d6ccaB6560B TAIKO_L2_ADDRESS=0x7633740000000000000000000000000000010001 # P2P @@ -25,12 +25,12 @@ NETHERMIND_OP_LOG_LEVEL=debug # If you are using a local Holesky L1 node, you can refer to it as "http://host.docker.internal:8545" and "ws://host.docker.internal:8546", which refer to the default ports in the .env for an eth-docker L1 node. # However, you may need to add this host to docker-compose.yml. If that does not work, you can try the private local ip address (e.g. http://192.168.1.15:8545). You can find that with `ip addr show` or a similar command. # In addition, you can use your public ip address followed by the specific ports for http and ws (e.g. http://82.168.1.15:8545). You can find that with `hostname -I | awk '{print $1}'`. -L1_ENDPOINT_WS= +L1_ENDPOINT_WS=ws://host.docker.internal:32003 # HTTP RPC endpoint of a L1 beacon node. Everything behind the top-level domain is ignored. Make sure you don't need to work with subdirectories. The path will always be /eth/v1... # If you are using a local Holesky L1 node, you can refer to it as "http://host.docker.internal:5052", which refer to the default REST port in the .env for an eth-docker L1 node. # Or follow the recommendations for http RPC endoint using the default REST port "5052", (e.g. http://82.168.1.15:5052). -L1_BEACON_HTTP= - +L1_BEACON_HTTP=http://host.docker.internal:33001 +OWNER_PRIVATE_KEY=0xbcdf20249abf0ed6d944c0288fad489e33f66b3960d9e6229c1cd214ed3bbe31 ############################### OPTIONAL ##################################### # If you want to be a prover who generates and submits zero knowledge proofs of proposed L2 blocks, you need to change # `ENABLE_PROVER` to true and set `L1_PROVER_PRIVATE_KEY`. @@ -53,6 +53,9 @@ MIN_TAIKO_BALANCE= # without the original prover submitting a proof.). PROVE_UNASSIGNED_BLOCKS=false +RISC0_VERIFIER=0xA2C4Ef228de6BA701660e75Cb06f1c9b29E53069 +SP1_VERIFIER=0x9c63682FC2d397Aa47471c046cE57b095d7195D7 +SGX_VERIFIER=0xdFb2fAc1519eDA2b3ee1Edf578ee0509DC8633f7 RAIKO_REQUEST_TIMEOUT=60s # If you want to be a proposer who proposes L2 execution engine's transactions in mempool to Taiko L1 protocol diff --git a/docker-compose.yml b/docker-compose.yml index 4a65582..1b7becd 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -55,7 +55,7 @@ services: - blockscout taiko_client_driver: - image: nethsurge/taiko-client:mptest + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always @@ -84,7 +84,7 @@ services: - blockscout taiko_client_proposer: - image: nethsurge/taiko-client:mptest + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always @@ -139,7 +139,7 @@ services: - blockscout taiko_client_prover_relayer: - image: nethsurge/taiko-client:mptest + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-prover-relayer-client restart: unless-stopped pull_policy: always @@ -161,6 +161,10 @@ services: - --prover.capacity=${PROVER_CAPACITY} - --tx.notInMempoolTimeout=30s - --tx.resubmissionTimeout=10s + # Composite Proof + - --sgxVerifier=${SGX_VERIFIER} + - --sp1Verifier=${SP1_VERIFIER} + - --risc0Verifier=${RISC0_VERIFIER} - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} - --raiko.host=${SGX_RAIKO_HOST} - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} @@ -185,6 +189,42 @@ services: - prover - blockscout + taiko-set-bridge-address: + image: nethsurge/protocol:composite-proof + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${CHAIN_ID} + ADDRESS: 0x72bCbB3f339aF622c28a26488Eed9097a2977404 + NAME: 0x6272696467650000000000000000000000000000000000000000000000000000 + PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 + FORK_URL: http://l2-nethermind-execution-client:8547 + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' + networks: + - surge + + taiko-set-signal-service-address: + image: nethsurge/protocol:composite-proof + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${CHAIN_ID} + ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 + NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 + PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 + FORK_URL: http://l2-nethermind-execution-client:8547 + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' + networks: + - surge + taiko-blockscout-postgres: image: postgres:alpine container_name: taiko-blockscout-postgres From 8e24e025407d3d901e05ec71fc7a341cf9a4fd09 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Thu, 12 Dec 2024 17:53:23 +1100 Subject: [PATCH 05/13] fix: update domain for set address services --- .env.sample | 1 + docker-compose.yml | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.env.sample b/.env.sample index 6eeb518..acf709b 100644 --- a/.env.sample +++ b/.env.sample @@ -1,6 +1,7 @@ ############################### DEFAULT ##################################### # Chain ID CHAIN_ID=763374 +L1_CHAIN_ID=3151908 # Exposed ports PORT_PROMETHEUS=9091 diff --git a/docker-compose.yml b/docker-compose.yml index 1b7becd..b0e22cd 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -139,10 +139,10 @@ services: - blockscout taiko_client_prover_relayer: - image: nethsurge/taiko-client:composite-proof + image: composite-proof-debug:latest container_name: l2-taiko-prover-relayer-client restart: unless-stopped - pull_policy: always + # pull_policy: always depends_on: - nethermind_execution_l2 - taiko_client_driver @@ -193,7 +193,7 @@ services: image: nethsurge/protocol:composite-proof environment: FOUNDRY_PROFILE: layer1 - DOMAIN: ${CHAIN_ID} + DOMAIN: ${L1_CHAIN_ID} ADDRESS: 0x72bCbB3f339aF622c28a26488Eed9097a2977404 NAME: 0x6272696467650000000000000000000000000000000000000000000000000000 PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 @@ -206,12 +206,14 @@ services: 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' networks: - surge + profiles: + - set-bridge taiko-set-signal-service-address: image: nethsurge/protocol:composite-proof environment: FOUNDRY_PROFILE: layer1 - DOMAIN: ${CHAIN_ID} + DOMAIN: ${L1_CHAIN_ID} ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 @@ -224,6 +226,8 @@ services: 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' networks: - surge + profiles: + - set-signal-service taiko-blockscout-postgres: image: postgres:alpine From bce3d52fb793815f84ba65c42f4fda29480d682e Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Thu, 12 Dec 2024 17:54:33 +1100 Subject: [PATCH 06/13] debug: update l1.proverPrivKey --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index b0e22cd..d538145 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -157,7 +157,7 @@ services: - --l2.http=http://l2-nethermind-execution-client:8547 - --taikoL1=${TAIKO_L1_ADDRESS} - --taikoL2=${TAIKO_L2_ADDRESS} - - --l1.proverPrivKey=${L1_PROPOSER_PRIVATE_KEY} + - --l1.proverPrivKey=${L1_PROVER_PRIVATE_KEY} - --prover.capacity=${PROVER_CAPACITY} - --tx.notInMempoolTimeout=30s - --tx.resubmissionTimeout=10s From 24be3d940c130cd5d80a20c778830cc1591a7b97 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Thu, 12 Dec 2024 17:57:05 +1100 Subject: [PATCH 07/13] fix: update images --- docker-compose.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index d538145..6aa3914 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -55,7 +55,7 @@ services: - blockscout taiko_client_driver: - image: nethsurge/taiko-client:composite-proof + image: nethsurge/taiko-client:composite-proof-debug container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always @@ -84,7 +84,7 @@ services: - blockscout taiko_client_proposer: - image: nethsurge/taiko-client:composite-proof + image: nethsurge/taiko-client:composite-proof-debug container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always @@ -139,7 +139,7 @@ services: - blockscout taiko_client_prover_relayer: - image: composite-proof-debug:latest + image: nethsurge/taiko-client:composite-proof-debug container_name: l2-taiko-prover-relayer-client restart: unless-stopped # pull_policy: always @@ -190,7 +190,7 @@ services: - blockscout taiko-set-bridge-address: - image: nethsurge/protocol:composite-proof + image: nethsurge/protocol:composite-proof-debug environment: FOUNDRY_PROFILE: layer1 DOMAIN: ${L1_CHAIN_ID} @@ -210,7 +210,7 @@ services: - set-bridge taiko-set-signal-service-address: - image: nethsurge/protocol:composite-proof + image: nethsurge/protocol:composite-proof-debug environment: FOUNDRY_PROFILE: layer1 DOMAIN: ${L1_CHAIN_ID} From 5e5cfa4089f5ce56a2bcaba2feb1a62d5977eb7f Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Wed, 18 Dec 2024 15:42:02 +1100 Subject: [PATCH 08/13] debug: update set signal service --- docker-compose.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 6aa3914..a7842ab 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -213,8 +213,8 @@ services: image: nethsurge/protocol:composite-proof-debug environment: FOUNDRY_PROFILE: layer1 - DOMAIN: ${L1_CHAIN_ID} - ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 + DOMAIN: ${CHAIN_ID} + ADDRESS: 0x7633740000000000000000000000000000000005 NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 FORK_URL: http://l2-nethermind-execution-client:8547 From 466bae5861bededf8a027996851f08c50494a4d5 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Wed, 18 Dec 2024 16:10:51 +1100 Subject: [PATCH 09/13] Revert "debug: update set signal service" This reverts commit 5e5cfa4089f5ce56a2bcaba2feb1a62d5977eb7f. --- docker-compose.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index a7842ab..6aa3914 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -213,8 +213,8 @@ services: image: nethsurge/protocol:composite-proof-debug environment: FOUNDRY_PROFILE: layer1 - DOMAIN: ${CHAIN_ID} - ADDRESS: 0x7633740000000000000000000000000000000005 + DOMAIN: ${L1_CHAIN_ID} + ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 FORK_URL: http://l2-nethermind-execution-client:8547 From 12b0571510ef830d3b58c1bf35bad439f3ea025a Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Thu, 19 Dec 2024 21:22:00 +1100 Subject: [PATCH 10/13] debug: update taiko geth docker compose for testing --- docker-compose-prover.yml | 213 +++++++++++++++++++++++++++++++++----- 1 file changed, 187 insertions(+), 26 deletions(-) diff --git a/docker-compose-prover.yml b/docker-compose-prover.yml index 5209187..2ac9560 100644 --- a/docker-compose-prover.yml +++ b/docker-compose-prover.yml @@ -10,8 +10,9 @@ services: - l2_execution_engine_data:/data/taiko-geth ports: - "6061:6060" - - "8549:8545" - - "8550:8546" + - "8547:8545" + - "8548:8546" + - "8551:8551" - "30307:30306" - "30307:30306/udp" command: | @@ -35,13 +36,15 @@ services: --port 30306 --discovery.port 30306 ${GETH_ADDITIONAL_ARGS:-} + networks: + - surge profiles: - l2_execution_engine - prover - proposer taiko_client_driver: - image: nethsurge/taiko-client:f042ca8 + image: nethsurge/taiko-client:composite-proof restart: unless-stopped pull_policy: always depends_on: @@ -61,20 +64,50 @@ services: - --taikoL1=${TAIKO_L1_ADDRESS} - --taikoL2=${TAIKO_L2_ADDRESS} - --jwtSecret=/data/taiko-geth/geth/jwtsecret + networks: + - surge profiles: - l2_execution_engine - prover - proposer + taiko_client_proposer: + image: nethsurge/taiko-client:composite-proof + restart: unless-stopped + pull_policy: always + depends_on: + - l2_execution_engine + - taiko_client_driver + env_file: + - .env + entrypoint: + - taiko-client + command: + - proposer + - --l1.ws=${L1_ENDPOINT_WS} + - --l2.http=http://l2_execution_engine:8545 + - --l2.auth=http://l2_execution_engine:8551 + - --taikoL1=${TAIKO_L1_ADDRESS} + - --taikoL2=${TAIKO_L2_ADDRESS} + - --jwtSecret=/data/taiko-geth/geth/jwtsecret + - --l1.proposerPrivKey=${L1_PROPOSER_PRIVATE_KEY} + - --l2.suggestedFeeRecipient=${L2_SUGGESTED_FEE_RECIPIENT} + - --tx.notInMempoolTimeout=30s + - --tx.resubmissionTimeout=10s + - --epoch.interval=5s + - --checkProfitability=false + networks: + - surge + profiles: + - proposer + taiko_client_prover_relayer: - image: nethsurge/taiko-client:f042ca8 + image: nethsurge/taiko-client:composite-proof restart: unless-stopped pull_policy: always depends_on: - l2_execution_engine - taiko_client_driver - ports: - - "9877:9876" env_file: - .env entrypoint: @@ -86,31 +119,159 @@ services: - --l2.http=http://l2_execution_engine:8545 - --taikoL1=${TAIKO_L1_ADDRESS} - --taikoL2=${TAIKO_L2_ADDRESS} - - --l1.proverPrivKey=${L1_PROPOSER_PRIVATE_KEY} + - --l1.proverPrivKey=${L1_PROVER_PRIVATE_KEY} - --prover.capacity=${PROVER_CAPACITY} - - --raiko.host=${SGX_RAIKO_HOST} - --tx.notInMempoolTimeout=30s - --tx.resubmissionTimeout=10s - # - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} - # conditioned - # - --proverSet ${PROVER_SET} - # - --prover.allowance ${TOKEN_ALLOWANCE} - # - --prover.minEthBalance ${MIN_ETH_BALANCE} - # - --prover.minTaikoTokenBalance ${MIN_TAIKO_BALANCE} - # - --prover.proveUnassignedBlocks - # - --tx.feeLimitMultiplier ${TX_FEE_LIMIT_MULTIPLIER} - # - --tx.feeLimitThreshold ${TX_FEE_LIMIT_THRESHOLD} - # - --tx.gasLimit ${TX_GAS_LIMIT} - # - --tx.minBaseFee ${TX_MIN_BASEFEE} - # - --tx.minTipCap ${TX_MIN_TIP_CAP} - # - --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL} - # - --tx.numConfirmations ${TX_NUM_CONFIRMATIONS} - # - --tx.receiptQueryInterval ${TX_RECEIPT_QUERY} - # - --tx.resubmissionTimeout ${TX_RESUBMISSION} - # - --tx.safeAbortNonceTooLowCount ${TX_SAFE_ABORT_NONCE_TOO_LOW} - # - --tx.sendTimeout ${TX_SEND_TIMEOUT} + - --sgxVerifier=${SGX_VERIFIER} + - --sp1Verifier=${SP1_VERIFIER} + - --risc0Verifier=${RISC0_VERIFIER} + - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} + - --raiko.host=${SGX_RAIKO_HOST} + - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} + - --verbosity=4 profiles: - prover + taiko-set-bridge-address: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L1_CHAIN_ID} + ADDRESS: 0x72bCbB3f339aF622c28a26488Eed9097a2977404 + NAME: 0x6272696467650000000000000000000000000000000000000000000000000000 + PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 + FORK_URL: http://l2_execution_engine:8545 + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2_execution_engine:8545 --broadcast -vvv' + networks: + - surge + profiles: + - set-bridge + + taiko-set-signal-service-address: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L1_CHAIN_ID} + ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 + NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 + PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 + FORK_URL: http://l2_execution_engine:8545 + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2_execution_engine:8545 --broadcast -vvv' + networks: + - surge + profiles: + - set-signal-service + + taiko-blockscout-postgres: + image: postgres:alpine + container_name: taiko-blockscout-postgres + restart: unless-stopped + pull_policy: always + depends_on: + - l2_execution_engine + - taiko_client_driver + volumes: + - ./blockscout-postgres-data:/var/lib/postgresql/data + ports: + - 5432:5432 + environment: + POSTGRES_DB: blockscout + POSTGRES_USER: postgres + POSTGRES_PASSWORD: MyPassword1! + PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin + GOSU_VERSION: 1.17 + PG_MAJOR: 17 + PG_VERSION: 17.0 + PG_SHA256: 7e276131c0fdd6b62588dbad9b3bb24b8c3498d5009328dba59af16e819109de + DOCKER_PG_LLVM_DEPS: llvm15-dev \t\tclang15 + PGDATA: /var/lib/postgresql/data + command: + - "-c" + - "max_connections=1000" + networks: + - surge + profiles: + - blockscout + + taiko-blockscout-verif: + image: ghcr.io/blockscout/smart-contract-verifier:v1.6.0 + container_name: taiko-blockscout-verif + restart: unless-stopped + pull_policy: always + depends_on: + - l2_execution_engine + - taiko_client_driver + ports: + - 8050:8050 + environment: + SMART_CONTRACT_VERIFIER__SERVER__HTTP__ADDR: 0.0.0.0:8050 + PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin + APP_USER: app + SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED: true + SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL: https://solc-bin.ethereum.org/linux-amd64/list.json + command: + - "./smart-contract-verifier-server" + networks: + - surge + profiles: + - blockscout + + taiko-blockscout: + image: blockscout/blockscout:6.6.0 + container_name: taiko-blockscout + restart: unless-stopped + pull_policy: always + depends_on: + - l2_execution_engine + - taiko_client_driver + ports: + - 4000:4000 + environment: + DATABASE_URL: postgresql://postgres:MyPassword1!@taiko-blockscout-postgres:5432/blockscout + API_V2_ENABLED: true + ETHEREUM_JSONRPC_VARIANT: nethermind + MICROSERVICE_SC_VERIFIER_URL: http://taiko-blockscout-verif:8050/api + ETHEREUM_JSONRPC_HTTP_URL: http://l2_execution_engine:8545/ + INDEXER_DISABLE_PENDING_TRANSACTIONS_FETCHER: true + SUBNETWORK: Kurtosis + ETHEREUM_JSONRPC_TRACE_URL: http://l2_execution_engine:8545/ + COIN: ETH + MICROSERVICE_SC_VERIFIER_TYPE: sc_verifier + PORT: 4000 + MICROSERVICE_SC_VERIFIER_ENABLED: true + ECTO_USE_SSL: false + SECRET_KEY_BASE: 56NtB48ear7+wMSf0IQuWDAAazhpb31qyc7GiyspBP2vh7t5zlCsF5QDv76chXeN + CHAIN_ID: 763374 + SHOW_TESTNET_LABEL: true + DISABLE_EXCHANGE_RATES: true + DISABLE_KNOWN_TOKENS: true + INDEXER_INTERNAL_TRANSACTIONS_BATCH_SIZE: 10000 + INDEXER_HIDE_INDEXING_PROGRESS_ALERT: false + PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin + RELEASE_VERSION: 6.6.0 + CHAIN_TYPE: + BRIDGED_TOKENS_ENABLED: + BLOCKSCOUT_VERSION: v6.6.0-beta + SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED: true + SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL: https://solc-bin.ethereum.org/linux-amd64/list.json + command: + - "/bin/sh" + - "-c" + - "bin/blockscout eval \"Elixir.Explorer.ReleaseTasks.create_and_migrate()\" && bin/blockscout start" + networks: + - surge + profiles: + - blockscout volumes: l2_execution_engine_data: From 90d8e8635b7200017c0c09b0d59ad21e745e869c Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Fri, 20 Dec 2024 20:10:53 +1100 Subject: [PATCH 11/13] feat: update proposer annd prover flags and nethermind EL image --- docker-compose.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 6aa3914..bdb3d73 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,6 +1,6 @@ services: nethermind_execution_l2: - image: nethermindeth/nethermind:surge-177139a04 + image: nethermindeth/nethermind:surge-19b6c6906 container_name: l2-nethermind-execution-client restart: unless-stopped pull_policy: always @@ -111,6 +111,9 @@ services: - --tx.notInMempoolTimeout=30s - --tx.resubmissionTimeout=10s - --epoch.interval=5s + - --checkProfitability=false + - --allowEmptyBlocks=false + # should be false for testnet # - --surge.gasNeededForProposingBlock=165000 # - --surge.gasNeededForProvingBlock=100000 # - --surge.offChainCosts=50000000000000 @@ -142,7 +145,7 @@ services: image: nethsurge/taiko-client:composite-proof-debug container_name: l2-taiko-prover-relayer-client restart: unless-stopped - # pull_policy: always + pull_policy: always depends_on: - nethermind_execution_l2 - taiko_client_driver @@ -168,6 +171,8 @@ services: - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} - --raiko.host=${SGX_RAIKO_HOST} - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} + - --verbosity=4 + - --tx.gasLimit=1000000 # conditioned # - --proverSet ${PROVER_SET} # - --prover.allowance ${TOKEN_ALLOWANCE} From a7ef011eed4fe0b098ab22d8e2fe787b7587a0d6 Mon Sep 17 00:00:00 2001 From: nmjustinchan Date: Mon, 23 Dec 2024 13:16:27 +1100 Subject: [PATCH 12/13] debug: update taiko client and protocol images --- docker-compose.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index bdb3d73..a895473 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -55,7 +55,7 @@ services: - blockscout taiko_client_driver: - image: nethsurge/taiko-client:composite-proof-debug + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-consensus-client restart: unless-stopped pull_policy: always @@ -84,7 +84,7 @@ services: - blockscout taiko_client_proposer: - image: nethsurge/taiko-client:composite-proof-debug + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always @@ -142,7 +142,7 @@ services: - blockscout taiko_client_prover_relayer: - image: nethsurge/taiko-client:composite-proof-debug + image: nethsurge/taiko-client:composite-proof container_name: l2-taiko-prover-relayer-client restart: unless-stopped pull_policy: always @@ -195,7 +195,7 @@ services: - blockscout taiko-set-bridge-address: - image: nethsurge/protocol:composite-proof-debug + image: nethsurge/protocol:composite-proof environment: FOUNDRY_PROFILE: layer1 DOMAIN: ${L1_CHAIN_ID} @@ -215,7 +215,7 @@ services: - set-bridge taiko-set-signal-service-address: - image: nethsurge/protocol:composite-proof-debug + image: nethsurge/protocol:composite-proof environment: FOUNDRY_PROFILE: layer1 DOMAIN: ${L1_CHAIN_ID} From 56cfeffdfca8e8c587da3c6dce8003b276109a9c Mon Sep 17 00:00:00 2001 From: Justin Chan Date: Wed, 25 Dec 2024 16:41:21 +1100 Subject: [PATCH 13/13] refac: update docker compose and env sample --- .env.sample | 99 +++++--- docker-compose-protocol.yml | 78 +++++++ docker-compose-prover.yml | 277 ---------------------- docker-compose.yml | 299 ++++++++---------------- script/start-driver.sh | 12 +- script/start-proposer.sh | 23 +- script/start-prover-relayer.sh | 26 ++- chainspec.json => static/chainspec.json | 0 jwtsecret => static/jwtsecret | 0 9 files changed, 277 insertions(+), 537 deletions(-) create mode 100644 docker-compose-protocol.yml delete mode 100644 docker-compose-prover.yml rename chainspec.json => static/chainspec.json (100%) rename jwtsecret => static/jwtsecret (100%) diff --git a/.env.sample b/.env.sample index acf709b..a5caf3f 100644 --- a/.env.sample +++ b/.env.sample @@ -1,49 +1,89 @@ ############################### DEFAULT ##################################### -# Chain ID -CHAIN_ID=763374 + +BRIDGE_32_BYTES=0x6272696467650000000000000000000000000000000000000000000000000000 +SIGNAL_SERVICE_32_BYTES=0x7369676e616c5f73657276696365000000000000000000000000000000000000 + +RISC0_VERIFIER=0xA2C4Ef228de6BA701660e75Cb06f1c9b29E53069 +SP1_VERIFIER=0x9c63682FC2d397Aa47471c046cE57b095d7195D7 +SGX_VERIFIER=0xdFb2fAc1519eDA2b3ee1Edf578ee0509DC8633f7 + +# L1 L1_CHAIN_ID=3151908 +L1_BRIDGE_ADDRESS=0x72bCbB3f339aF622c28a26488Eed9097a2977404 +L1_SIGNAL_SERVICE_ADDRESS=0x00c042C4D5D913277CE16611a2ce6e9003554aD5 +L1_SHARED_ADDRESS_MANAGER=0x7633740000000000000000000000000000000006 +TAIKO_L1_ADDRESS=0xaE37C7A711bcab9B0f8655a97B738d6ccaB6560B + +L1_ENDPOINT_HTTP=http://host.docker.internal:32002 +L1_ENDPOINT_WS=ws://host.docker.internal:32003 +L1_BEACON_HTTP=http://host.docker.internal:33001 + +# L2 +L2_CHAIN_ID=763374 +L2_GENESIS_HASH=0xbeced3738f1246571cccabc82a1e6cbd9ed9d5f7ed2b6c7ded28f9722317bd9e + +L2_BRIDGE_ADDRESS=0x72bCbB3f339aF622c28a26488Eed9097a2977404 +L2_SIGNAL_SERVICE_ADDRESS=0x00c042C4D5D913277CE16611a2ce6e9003554aD5 +L2_SHARED_ADDRESS_MANAGER=0x7633740000000000000000000000000000000006 +TAIKO_L2_ADDRESS=0x7633740000000000000000000000000000010001 + +L2_ENDPOINT_HTTP=http://host.docker.internal:8547 +L2_ENDPOINT_WS=ws://host.docker.internal:8548 +L2_AUTH_HTTP=http://host.docker.internal:8552 + +# Nethermind log level +NETHERMIND_LOG_LEVEL=debug + +# Surge +PROPOSING_BLOCK_GAS=165000 +PROVING_BLOCK_GAS=100000 +OFF_CHAIN_COSTS=50000000000000 +PRICE_FLUCTUATION_MODIFIER=15 + # Exposed ports -PORT_PROMETHEUS=9091 -PORT_GRAFANA=3001 +L2_METRICS_PORT=8018 +L2_HTTP_PORT=8547 +L2_WS_PORT=8548 +L2_ENGINE_API_PORT=8552 +L2_NETWORK_DISCOVERY_PORT=30313 +POSTGRES_PORT=5432 +VERIFIER_PORT=8050 +BLOCKSCOUT_PORT=4000 +PROMETHEUS_PORT=9091 +GRAFANA_PORT=3001 # Comma separated L2 execution engine bootnode URLs for P2P discovery bootstrap BOOT_NODES= -# Taiko protocol contract addresses -TAIKO_L1_ADDRESS=0xaE37C7A711bcab9B0f8655a97B738d6ccaB6560B -TAIKO_L2_ADDRESS=0x7633740000000000000000000000000000010001 - # P2P DISABLE_P2P_SYNC=false -P2P_SYNC_URL=https://rpc.hekla.taiko.xyz - -# Nethermind log level -NETHERMIND_OP_LOG_LEVEL=debug +P2P_SYNC_URL= ############################### REQUIRED ##################################### -# L1 Holesky RPC endpoints (you will need an RPC provider such as BlockPi, or run a full Holesky node yourself). -# If you are using a local Holesky L1 node, you can refer to it as "http://host.docker.internal:8545" and "ws://host.docker.internal:8546", which refer to the default ports in the .env for an eth-docker L1 node. -# However, you may need to add this host to docker-compose.yml. If that does not work, you can try the private local ip address (e.g. http://192.168.1.15:8545). You can find that with `ip addr show` or a similar command. -# In addition, you can use your public ip address followed by the specific ports for http and ws (e.g. http://82.168.1.15:8545). You can find that with `hostname -I | awk '{print $1}'`. -L1_ENDPOINT_WS=ws://host.docker.internal:32003 -# HTTP RPC endpoint of a L1 beacon node. Everything behind the top-level domain is ignored. Make sure you don't need to work with subdirectories. The path will always be /eth/v1... -# If you are using a local Holesky L1 node, you can refer to it as "http://host.docker.internal:5052", which refer to the default REST port in the .env for an eth-docker L1 node. -# Or follow the recommendations for http RPC endoint using the default REST port "5052", (e.g. http://82.168.1.15:5052). -L1_BEACON_HTTP=http://host.docker.internal:33001 +# Owner private key for contract deployments OWNER_PRIVATE_KEY=0xbcdf20249abf0ed6d944c0288fad489e33f66b3960d9e6229c1cd214ed3bbe31 + +# Profitability check +CHECK_PROFITABILITY=false + +# Allow empty blocks +ALLOW_EMPTY_BLOCKS=false + ############################### OPTIONAL ##################################### # If you want to be a prover who generates and submits zero knowledge proofs of proposed L2 blocks, you need to change # `ENABLE_PROVER` to true and set `L1_PROVER_PRIVATE_KEY`. ENABLE_PROVER=true # SGX Raiko service endpoint, required if not running a guardian prover. SGX_RAIKO_HOST= +# ZKVM Raiko service endpoint. RAIKO_HOST_ZKVM= +RAIKO_REQUEST_TIMEOUT=60s # How many provers you want to run concurrently. PROVER_CAPACITY=1 # A L1 account private key (with a balance of TTKOh deposited on TaikoL1) which will be used to sign the bond for proving the block. # WARNING: only use a test account, pasting your private key in plain text here is not secure. -L1_PROVER_PRIVATE_KEY=ab63b23eb7941c1251757e24b3d2350d2bc05c3c388d06f8fe6feafefb1e8c70 +L1_PROVER_PRIVATE_KEY=0xab63b23eb7941c1251757e24b3d2350d2bc05c3c388d06f8fe6feafefb1e8c70 # Amount to approve TaikoL1 contracts for TaikoToken usage. i.e 250 TTKOh = 250 TOKEN_ALLOWANCE= # Minimum ETH balance (in ETH) a prover wants to keep. @@ -54,16 +94,11 @@ MIN_TAIKO_BALANCE= # without the original prover submitting a proof.). PROVE_UNASSIGNED_BLOCKS=false -RISC0_VERIFIER=0xA2C4Ef228de6BA701660e75Cb06f1c9b29E53069 -SP1_VERIFIER=0x9c63682FC2d397Aa47471c046cE57b095d7195D7 -SGX_VERIFIER=0xdFb2fAc1519eDA2b3ee1Edf578ee0509DC8633f7 -RAIKO_REQUEST_TIMEOUT=60s - # If you want to be a proposer who proposes L2 execution engine's transactions in mempool to Taiko L1 protocol # contract (be a "mining L2 node"), you need to change `ENABLE_PROPOSER` to true, then fill `L1_PROPOSER_PRIVATE_KEY`. ENABLE_PROPOSER=true # A L1 account (with balance) private key who will send TaikoL1.proposeBlock transactions. -L1_PROPOSER_PRIVATE_KEY=53321db7c1e331d93a11a41d16f004d7ff63972ec8ec7c25db329728ceeb1710 +L1_PROPOSER_PRIVATE_KEY=0x53321db7c1e331d93a11a41d16f004d7ff63972ec8ec7c25db329728ceeb1710 # Address of the proposed block's suggested L2 fee recipient. L2_SUGGESTED_FEE_RECIPIENT=0xD51a7E12997f6f1D04AcCC2b4053307a62b373cb # Comma-delineated list (no spaces) of prover endpoints proposer should query when attempting to propose a block @@ -72,6 +107,8 @@ L2_SUGGESTED_FEE_RECIPIENT=0xD51a7E12997f6f1D04AcCC2b4053307a62b373cb BLOB_ALLOWED=true # Minimum tip (in GWei) for a transaction to propose. EPOCH_MIN_TIP= +# Time interval to propose L2 pending transactions +EPOCH_INTERVAL=5s # ProverSet Address: We highly recommend you consult the deploy a proverset guide and use separate EOAs for prover and proposer to prevent nonce issues. PROVER_SET= @@ -85,19 +122,19 @@ TX_FEE_LIMIT_MULTIPLIER= # The minimum threshold (in GWei) at which fee bumping starts to be capped. Allows arbitrary fee bumps below this threshold. TX_FEE_LIMIT_THRESHOLD= # Gas limit will be used for transactions (0 means using gas estimation) -TX_GAS_LIMIT= +TX_GAS_LIMIT=1000000 # Enforces a minimum base fee (in GWei) to assume when determining tx fees. 1 GWei by default TX_MIN_BASEFEE= # Enforces a minimum tip cap (in GWei) to use when determining tx fees. 1 GWei by default. TX_MIN_TIP_CAP= # Timeout for aborting a tx send if the tx does not make it to the mempool. -TX_NOT_IN_MEMPOOL_TIMEOUT= +TX_NOT_IN_MEMPOOL_TIMEOUT=30s # Number of confirmations which we will wait after sending a transaction TX_NUM_CONFIRMATIONS= # Frequency to poll for receipts TX_RECEIPT_QUERY_INTERVAL= # Duration we will wait before resubmitting a transaction to L1 -TX_RESUBMISSION= +TX_RESUBMISSION=10s # Number of ErrNonceTooLow observations required to give up on a tx at a particular nonce without receiving confirmation TX_SAFE_ABORT_NONCE_TOO_LOW= # Timeout for sending transactions. If 0 it is disabled. diff --git a/docker-compose-protocol.yml b/docker-compose-protocol.yml new file mode 100644 index 0000000..1c6d0e1 --- /dev/null +++ b/docker-compose-protocol.yml @@ -0,0 +1,78 @@ +services: + set-bridge-address-l1: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L2_CHAIN_ID} + ADDRESS: ${L2_BRIDGE_ADDRESS} + NAME: ${BRIDGE_32_BYTES} + PROXY_ADDRESS: ${L1_SHARED_ADDRESS_MANAGER} + FORK_URL: ${L1_ENDPOINT_HTTP} + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url "${FORK_URL}" --broadcast -vvv' + set-signal-service-address-l1: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L2_CHAIN_ID} + ADDRESS: ${L2_SIGNAL_SERVICE_ADDRESS} + NAME: ${SIGNAL_SERVICE_32_BYTES} + PROXY_ADDRESS: ${L1_SHARED_ADDRESS_MANAGER} + FORK_URL: ${L1_ENDPOINT_HTTP} + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url "${FORK_URL}" --broadcast -vvv' + networks: + - surge + profiles: + - set-signal-service + + set-bridge-address-l2: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L1_CHAIN_ID} + ADDRESS: ${L1_BRIDGE_ADDRESS} + NAME: ${BRIDGE_32_BYTES} + PROXY_ADDRESS: ${L2_SHARED_ADDRESS_MANAGER} + FORK_URL: ${L2_ENDPOINT_HTTP} + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url "${FORK_URL}" --broadcast -vvv' + networks: + - surge + profiles: + - set-bridge + + set-signal-service-address-l2: + image: nethsurge/protocol:composite-proof-debug + environment: + FOUNDRY_PROFILE: layer1 + DOMAIN: ${L1_CHAIN_ID} + ADDRESS: ${L2_SIGNAL_SERVICE_ADDRESS} + NAME: ${SIGNAL_SERVICE_32_BYTES} + PROXY_ADDRESS: ${L2_SHARED_ADDRESS_MANAGER} + FORK_URL: ${L2_ENDPOINT_HTTP} + PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + entrypoint: + - sh + - -c + command: > + 'forge script ./script/shared/SetAddress.s.sol --fork-url "${FORK_URL}" --broadcast -vvv' + networks: + - surge + profiles: + - set-signal-service +networks: + surge: + name: surge-network \ No newline at end of file diff --git a/docker-compose-prover.yml b/docker-compose-prover.yml deleted file mode 100644 index 2ac9560..0000000 --- a/docker-compose-prover.yml +++ /dev/null @@ -1,277 +0,0 @@ -services: - l2_execution_engine: - image: nethswitchboard/taiko-geth:surge - restart: unless-stopped - pull_policy: always - env_file: - - .env - stop_grace_period: 3m - volumes: - - l2_execution_engine_data:/data/taiko-geth - ports: - - "6061:6060" - - "8547:8545" - - "8548:8546" - - "8551:8551" - - "30307:30306" - - "30307:30306/udp" - command: | - --taiko - --networkid 763374 - --gcmode archive - --datadir /data/taiko-geth - --metrics - --metrics.addr "0.0.0.0" - --authrpc.addr "0.0.0.0" - --authrpc.vhosts "*" - --http - --http.api debug,eth,net,web3,txpool,taiko - --http.addr "0.0.0.0" - --http.vhosts "*" - --ws - --ws.api debug,eth,net,web3,txpool,taiko - --ws.addr "0.0.0.0" - --ws.origins "*" - --gpo.defaultprice "10000000" - --port 30306 - --discovery.port 30306 - ${GETH_ADDITIONAL_ARGS:-} - networks: - - surge - profiles: - - l2_execution_engine - - prover - - proposer - - taiko_client_driver: - image: nethsurge/taiko-client:composite-proof - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - env_file: - - .env - volumes: - - l2_execution_engine_data:/data/taiko-geth - entrypoint: - - taiko-client - command: - - driver - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.ws=ws://l2_execution_engine:8546 - - --l1.beacon=${L1_BEACON_HTTP} - - --l2.auth=http://l2_execution_engine:8551 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --jwtSecret=/data/taiko-geth/geth/jwtsecret - networks: - - surge - profiles: - - l2_execution_engine - - prover - - proposer - - taiko_client_proposer: - image: nethsurge/taiko-client:composite-proof - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - - taiko_client_driver - env_file: - - .env - entrypoint: - - taiko-client - command: - - proposer - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.http=http://l2_execution_engine:8545 - - --l2.auth=http://l2_execution_engine:8551 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --jwtSecret=/data/taiko-geth/geth/jwtsecret - - --l1.proposerPrivKey=${L1_PROPOSER_PRIVATE_KEY} - - --l2.suggestedFeeRecipient=${L2_SUGGESTED_FEE_RECIPIENT} - - --tx.notInMempoolTimeout=30s - - --tx.resubmissionTimeout=10s - - --epoch.interval=5s - - --checkProfitability=false - networks: - - surge - profiles: - - proposer - - taiko_client_prover_relayer: - image: nethsurge/taiko-client:composite-proof - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - - taiko_client_driver - env_file: - - .env - entrypoint: - - taiko-client - command: - - prover - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.ws=ws://l2_execution_engine:8546 - - --l2.http=http://l2_execution_engine:8545 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --l1.proverPrivKey=${L1_PROVER_PRIVATE_KEY} - - --prover.capacity=${PROVER_CAPACITY} - - --tx.notInMempoolTimeout=30s - - --tx.resubmissionTimeout=10s - - --sgxVerifier=${SGX_VERIFIER} - - --sp1Verifier=${SP1_VERIFIER} - - --risc0Verifier=${RISC0_VERIFIER} - - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} - - --raiko.host=${SGX_RAIKO_HOST} - - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} - - --verbosity=4 - profiles: - - prover - - taiko-set-bridge-address: - image: nethsurge/protocol:composite-proof-debug - environment: - FOUNDRY_PROFILE: layer1 - DOMAIN: ${L1_CHAIN_ID} - ADDRESS: 0x72bCbB3f339aF622c28a26488Eed9097a2977404 - NAME: 0x6272696467650000000000000000000000000000000000000000000000000000 - PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 - FORK_URL: http://l2_execution_engine:8545 - PRIVATE_KEY: ${OWNER_PRIVATE_KEY} - entrypoint: - - sh - - -c - command: > - 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2_execution_engine:8545 --broadcast -vvv' - networks: - - surge - profiles: - - set-bridge - - taiko-set-signal-service-address: - image: nethsurge/protocol:composite-proof-debug - environment: - FOUNDRY_PROFILE: layer1 - DOMAIN: ${L1_CHAIN_ID} - ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 - NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 - PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 - FORK_URL: http://l2_execution_engine:8545 - PRIVATE_KEY: ${OWNER_PRIVATE_KEY} - entrypoint: - - sh - - -c - command: > - 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2_execution_engine:8545 --broadcast -vvv' - networks: - - surge - profiles: - - set-signal-service - - taiko-blockscout-postgres: - image: postgres:alpine - container_name: taiko-blockscout-postgres - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - - taiko_client_driver - volumes: - - ./blockscout-postgres-data:/var/lib/postgresql/data - ports: - - 5432:5432 - environment: - POSTGRES_DB: blockscout - POSTGRES_USER: postgres - POSTGRES_PASSWORD: MyPassword1! - PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin - GOSU_VERSION: 1.17 - PG_MAJOR: 17 - PG_VERSION: 17.0 - PG_SHA256: 7e276131c0fdd6b62588dbad9b3bb24b8c3498d5009328dba59af16e819109de - DOCKER_PG_LLVM_DEPS: llvm15-dev \t\tclang15 - PGDATA: /var/lib/postgresql/data - command: - - "-c" - - "max_connections=1000" - networks: - - surge - profiles: - - blockscout - - taiko-blockscout-verif: - image: ghcr.io/blockscout/smart-contract-verifier:v1.6.0 - container_name: taiko-blockscout-verif - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - - taiko_client_driver - ports: - - 8050:8050 - environment: - SMART_CONTRACT_VERIFIER__SERVER__HTTP__ADDR: 0.0.0.0:8050 - PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin - APP_USER: app - SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED: true - SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL: https://solc-bin.ethereum.org/linux-amd64/list.json - command: - - "./smart-contract-verifier-server" - networks: - - surge - profiles: - - blockscout - - taiko-blockscout: - image: blockscout/blockscout:6.6.0 - container_name: taiko-blockscout - restart: unless-stopped - pull_policy: always - depends_on: - - l2_execution_engine - - taiko_client_driver - ports: - - 4000:4000 - environment: - DATABASE_URL: postgresql://postgres:MyPassword1!@taiko-blockscout-postgres:5432/blockscout - API_V2_ENABLED: true - ETHEREUM_JSONRPC_VARIANT: nethermind - MICROSERVICE_SC_VERIFIER_URL: http://taiko-blockscout-verif:8050/api - ETHEREUM_JSONRPC_HTTP_URL: http://l2_execution_engine:8545/ - INDEXER_DISABLE_PENDING_TRANSACTIONS_FETCHER: true - SUBNETWORK: Kurtosis - ETHEREUM_JSONRPC_TRACE_URL: http://l2_execution_engine:8545/ - COIN: ETH - MICROSERVICE_SC_VERIFIER_TYPE: sc_verifier - PORT: 4000 - MICROSERVICE_SC_VERIFIER_ENABLED: true - ECTO_USE_SSL: false - SECRET_KEY_BASE: 56NtB48ear7+wMSf0IQuWDAAazhpb31qyc7GiyspBP2vh7t5zlCsF5QDv76chXeN - CHAIN_ID: 763374 - SHOW_TESTNET_LABEL: true - DISABLE_EXCHANGE_RATES: true - DISABLE_KNOWN_TOKENS: true - INDEXER_INTERNAL_TRANSACTIONS_BATCH_SIZE: 10000 - INDEXER_HIDE_INDEXING_PROGRESS_ALERT: false - PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin - RELEASE_VERSION: 6.6.0 - CHAIN_TYPE: - BRIDGED_TOKENS_ENABLED: - BLOCKSCOUT_VERSION: v6.6.0-beta - SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED: true - SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL: https://solc-bin.ethereum.org/linux-amd64/list.json - command: - - "/bin/sh" - - "-c" - - "bin/blockscout eval \"Elixir.Explorer.ReleaseTasks.create_and_migrate()\" && bin/blockscout start" - networks: - - surge - profiles: - - blockscout -volumes: - l2_execution_engine_data: diff --git a/docker-compose.yml b/docker-compose.yml index a895473..1349bab 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -7,39 +7,39 @@ services: stop_grace_period: 3m tty: true volumes: - - ./jwtsecret:/tmp/jwt/jwtsecret - - ./chainspec.json:/chainspec.json + - ./static/jwtsecret:/tmp/jwt/jwtsecret + - ./static/chainspec.json:/chainspec.json networks: - surge ports: - - 30313:30313/tcp - - 30313:30313/udp - - 8018:8018 - - 8547:8547 - - 8548:8548 - - 8552:8552 + - ${L2_NETWORK_DISCOVERY_PORT}:${L2_NETWORK_DISCOVERY_PORT}/tcp + - ${L2_NETWORK_DISCOVERY_PORT}:${L2_NETWORK_DISCOVERY_PORT}/udp + - ${L2_METRICS_PORT}:${L2_METRICS_PORT} + - ${L2_HTTP_PORT}:${L2_HTTP_PORT} + - ${L2_WS_PORT}:${L2_WS_PORT} + - ${L2_ENGINE_API_PORT}:${L2_ENGINE_API_PORT} command: - --config=none - --datadir=/data/taiko-geth - --Init.ChainSpecPath=/chainspec.json - - --Init.GenesisHash=0xbeced3738f1246571cccabc82a1e6cbd9ed9d5f7ed2b6c7ded28f9722317bd9e + - --Init.GenesisHash=${L2_GENESIS_HASH} - --Init.DiscoveryEnabled=false - --Metrics.Enabled=true - - --Metrics.ExposePort=8018 + - --Metrics.ExposePort=${L2_METRICS_PORT} - --JsonRpc.Enabled=true - --JsonRpc.EnabledModules=[debug,eth,net,web3,txpool,rpc,subscribe,trace,personal,proof,parity,health] - --JsonRpc.Host=0.0.0.0 - - --JsonRpc.Port=8547 - - --JsonRpc.WebSocketsPort=8548 + - --JsonRpc.Port=${L2_HTTP_PORT} + - --JsonRpc.WebSocketsPort=${L2_WS_PORT} - --JsonRpc.JwtSecretFile=/tmp/jwt/jwtsecret - --JsonRpc.EngineHost=0.0.0.0 - - --JsonRpc.EnginePort=8552 - - --Network.DiscoveryPort=30313 - - --Network.P2PPort=30313 + - --JsonRpc.EnginePort=${L2_ENGINE_API_PORT} + - --Network.DiscoveryPort=${L2_NETWORK_DISCOVERY_PORT} + - --Network.P2PPort=${L2_NETWORK_DISCOVERY_PORT} - --Sync.FastSync=false - --Sync.SnapSync=false - --HealthChecks.Enabled=true - - --log=${NETHERMIND_OP_LOG_LEVEL} + - --log=${NETHERMIND_LOG_LEVEL} - --JsonRpc.MaxBatchResponseBodySize=335544320 - --JsonRpc.MaxBatchSize=102400 healthcheck: @@ -63,176 +63,61 @@ services: - nethermind_execution_l2 volumes: - ./execution-data-taiko:/data/taiko-geth - - ./jwtsecret:/tmp/jwt/jwtsecret + - ./static/jwtsecret:/tmp/jwt/jwtsecret + - ./script:/script + entrypoint: + - /bin/sh + - -c + - "/script/start-driver.sh" networks: - surge - entrypoint: - - taiko-client - command: - - driver - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.ws=ws://l2-nethermind-execution-client:8548 - - --l1.beacon=${L1_BEACON_HTTP} - - --l2.auth=http://l2-nethermind-execution-client:8552 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --jwtSecret=/tmp/jwt/jwtsecret profiles: - nethermind_execution_l2 - proposer - prover - blockscout - taiko_client_proposer: + taiko_client_prover_relayer: image: nethsurge/taiko-client:composite-proof - container_name: l2-taiko-proposer-client + container_name: l2-taiko-prover-relayer-client restart: unless-stopped pull_policy: always depends_on: - nethermind_execution_l2 - taiko_client_driver volumes: - - ./execution-data-taiko:/data/taiko-geth - - ./jwtsecret:/tmp/jwt/jwtsecret + - ./script:/script + entrypoint: + - /bin/sh + - -c + - "/script/start-prover-relayer.sh" networks: - surge - entrypoint: - - taiko-client - command: - - proposer - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.http=http://l2-nethermind-execution-client:8547 - - --l2.auth=http://l2-nethermind-execution-client:8552 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --jwtSecret=/tmp/jwt/jwtsecret - - --l1.proposerPrivKey=${L1_PROPOSER_PRIVATE_KEY} - - --l2.suggestedFeeRecipient=${L2_SUGGESTED_FEE_RECIPIENT} - - --tx.notInMempoolTimeout=30s - - --tx.resubmissionTimeout=10s - - --epoch.interval=5s - - --checkProfitability=false - - --allowEmptyBlocks=false - # should be false for testnet - # - --surge.gasNeededForProposingBlock=165000 - # - --surge.gasNeededForProvingBlock=100000 - # - --surge.offChainCosts=50000000000000 - # - --surge.priceFluctuationModifier=15 - # - --verbosity=4 - # conditioned - # - --epoch.minTip ${EPOCH_MIN_TIP} - # - --proverSet ${PROVER_SET} - # - --txPool.localsOnly - # - --txPool.locals ${TXPOOL_LOCALS} - # - --l1.blobAllowed - # - --tx.feeLimitMultiplier ${TX_FEE_LIMIT_MULTIPLIER} - # - --tx.feeLimitThreshold ${TX_FEE_LIMIT_THRESHOLD} - # - --tx.gasLimit ${TX_GAS_LIMIT} - # - --tx.minBaseFee ${TX_MIN_BASEFEE} - # - --tx.minTipCap ${TX_MIN_TIP_CAP} - # - --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL} - # - --tx.numConfirmations ${TX_NUM_CONFIRMATIONS} - # - --tx.receiptQueryInterval ${TX_RECEIPT_QUERY} - # - --tx.resubmissionTimeout ${TX_RESUBMISSION} - # - --tx.safeAbortNonceTooLowCount ${TX_SAFE_ABORT_NONCE_TOO_LOW} - # - --tx.sendTimeout ${TX_SEND_TIMEOUT} profiles: - - proposer - prover - blockscout - taiko_client_prover_relayer: + taiko_client_proposer: image: nethsurge/taiko-client:composite-proof - container_name: l2-taiko-prover-relayer-client + container_name: l2-taiko-proposer-client restart: unless-stopped pull_policy: always depends_on: - nethermind_execution_l2 - taiko_client_driver - networks: - - surge - entrypoint: - - taiko-client - command: - - prover - - --l1.ws=${L1_ENDPOINT_WS} - - --l2.ws=ws://l2-nethermind-execution-client:8548 - - --l2.http=http://l2-nethermind-execution-client:8547 - - --taikoL1=${TAIKO_L1_ADDRESS} - - --taikoL2=${TAIKO_L2_ADDRESS} - - --l1.proverPrivKey=${L1_PROVER_PRIVATE_KEY} - - --prover.capacity=${PROVER_CAPACITY} - - --tx.notInMempoolTimeout=30s - - --tx.resubmissionTimeout=10s - # Composite Proof - - --sgxVerifier=${SGX_VERIFIER} - - --sp1Verifier=${SP1_VERIFIER} - - --risc0Verifier=${RISC0_VERIFIER} - - --raiko.host.zkvm=${RAIKO_HOST_ZKVM} - - --raiko.host=${SGX_RAIKO_HOST} - - --raiko.requestTimeout=${RAIKO_REQUEST_TIMEOUT} - - --verbosity=4 - - --tx.gasLimit=1000000 - # conditioned - # - --proverSet ${PROVER_SET} - # - --prover.allowance ${TOKEN_ALLOWANCE} - # - --prover.minEthBalance ${MIN_ETH_BALANCE} - # - --prover.minTaikoTokenBalance ${MIN_TAIKO_BALANCE} - # - --prover.proveUnassignedBlocks - # - --tx.feeLimitMultiplier ${TX_FEE_LIMIT_MULTIPLIER} - # - --tx.feeLimitThreshold ${TX_FEE_LIMIT_THRESHOLD} - # - --tx.gasLimit ${TX_GAS_LIMIT} - # - --tx.minBaseFee ${TX_MIN_BASEFEE} - # - --tx.minTipCap ${TX_MIN_TIP_CAP} - # - --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL} - # - --tx.numConfirmations ${TX_NUM_CONFIRMATIONS} - # - --tx.receiptQueryInterval ${TX_RECEIPT_QUERY} - # - --tx.resubmissionTimeout ${TX_RESUBMISSION} - # - --tx.safeAbortNonceTooLowCount ${TX_SAFE_ABORT_NONCE_TOO_LOW} - # - --tx.sendTimeout ${TX_SEND_TIMEOUT} - profiles: - - prover - - blockscout - - taiko-set-bridge-address: - image: nethsurge/protocol:composite-proof - environment: - FOUNDRY_PROFILE: layer1 - DOMAIN: ${L1_CHAIN_ID} - ADDRESS: 0x72bCbB3f339aF622c28a26488Eed9097a2977404 - NAME: 0x6272696467650000000000000000000000000000000000000000000000000000 - PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 - FORK_URL: http://l2-nethermind-execution-client:8547 - PRIVATE_KEY: ${OWNER_PRIVATE_KEY} - entrypoint: - - sh - - -c - command: > - 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' - networks: - - surge - profiles: - - set-bridge - - taiko-set-signal-service-address: - image: nethsurge/protocol:composite-proof - environment: - FOUNDRY_PROFILE: layer1 - DOMAIN: ${L1_CHAIN_ID} - ADDRESS: 0x00c042C4D5D913277CE16611a2ce6e9003554aD5 - NAME: 0x7369676e616c5f73657276696365000000000000000000000000000000000000 - PROXY_ADDRESS: 0x7633740000000000000000000000000000000006 - FORK_URL: http://l2-nethermind-execution-client:8547 - PRIVATE_KEY: ${OWNER_PRIVATE_KEY} + volumes: + - ./execution-data-taiko:/data/taiko-geth + - ./script:/script entrypoint: - - sh + - /bin/sh - -c - command: > - 'forge script ./script/shared/SetAddress.s.sol --fork-url http://l2-nethermind-execution-client:8547 --broadcast -vvv' + - "/script/start-proposer.sh" networks: - surge profiles: - - set-signal-service + - proposer + - prover + - blockscout taiko-blockscout-postgres: image: postgres:alpine @@ -245,7 +130,7 @@ services: volumes: - ./blockscout-postgres-data:/var/lib/postgresql/data ports: - - 5432:5432 + - ${POSTGRES_PORT}:${POSTGRES_PORT} environment: POSTGRES_DB: blockscout POSTGRES_USER: postgres @@ -274,9 +159,9 @@ services: - nethermind_execution_l2 - taiko_client_driver ports: - - 8050:8050 + - ${VERIFIER_PORT}:${VERIFIER_PORT} environment: - SMART_CONTRACT_VERIFIER__SERVER__HTTP__ADDR: 0.0.0.0:8050 + SMART_CONTRACT_VERIFIER__SERVER__HTTP__ADDR: 0.0.0.0:${VERIFIER_PORT} PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin APP_USER: app SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED: true @@ -297,24 +182,24 @@ services: - nethermind_execution_l2 - taiko_client_driver ports: - - 4000:4000 + - ${BLOCKSCOUT_PORT}:${BLOCKSCOUT_PORT} environment: DATABASE_URL: postgresql://postgres:MyPassword1!@taiko-blockscout-postgres:5432/blockscout API_V2_ENABLED: true ETHEREUM_JSONRPC_VARIANT: nethermind - MICROSERVICE_SC_VERIFIER_URL: http://taiko-blockscout-verif:8050/api - ETHEREUM_JSONRPC_HTTP_URL: http://l2-nethermind-execution-client:8547/ + MICROSERVICE_SC_VERIFIER_URL: http://taiko-blockscout-verif:${VERIFIER_PORT}/api + ETHEREUM_JSONRPC_HTTP_URL: http://l2-nethermind-execution-client:${L2_HTTP_PORT}/ INDEXER_DISABLE_PENDING_TRANSACTIONS_FETCHER: true - SUBNETWORK: Kurtosis - ETHEREUM_JSONRPC_TRACE_URL: http://l2-nethermind-execution-client:8547/ + SUBNETWORK: Surge + ETHEREUM_JSONRPC_TRACE_URL: http://l2-nethermind-execution-client:${L2_HTTP_PORT}/ COIN: ETH MICROSERVICE_SC_VERIFIER_TYPE: sc_verifier - PORT: 4000 + PORT: ${BLOCKSCOUT_PORT} MICROSERVICE_SC_VERIFIER_ENABLED: true ECTO_USE_SSL: false SECRET_KEY_BASE: 56NtB48ear7+wMSf0IQuWDAAazhpb31qyc7GiyspBP2vh7t5zlCsF5QDv76chXeN - CHAIN_ID: 763374 - SHOW_TESTNET_LABEL: true + CHAIN_ID: ${L2_CHAIN_ID} + SHOW_TESTNET_LABEL: false DISABLE_EXCHANGE_RATES: true DISABLE_KNOWN_TOKENS: true INDEXER_INTERNAL_TRANSACTIONS_BATCH_SIZE: 10000 @@ -335,50 +220,50 @@ services: profiles: - blockscout - # prometheus: - # image: prom/prometheus:latest - # restart: unless-stopped - # ports: - # - ${PORT_PROMETHEUS}:9090 - # depends_on: - # - nethermind_execution_l2 - # - taiko_client_driver - # volumes: - # - ./docker/prometheus/l2:/etc/prometheus - # - prometheus_data:/prometheus - # command: - # - --log.level=debug - # - --config.file=/etc/prometheus/prometheus.yml - # profiles: - # - nethermind_execution_l2 - # - prover - # - proposer + prometheus: + image: prom/prometheus:latest + restart: unless-stopped + ports: + - ${PORT_PROMETHEUS}:${PORT_PROMETHEUS} + depends_on: + - nethermind_execution_l2 + - taiko_client_driver + volumes: + - ./docker/prometheus/l2:/etc/prometheus + - prometheus_data:/prometheus + command: + - --log.level=debug + - --config.file=/etc/prometheus/prometheus.yml + profiles: + - nethermind_execution_l2 + - prover + - proposer - # grafana: - # image: grafana/grafana:latest - # restart: unless-stopped - # ports: - # - ${PORT_GRAFANA}:3000 - # depends_on: - # - nethermind_execution_l2 - # - taiko_client_driver - # - prometheus - # environment: - # - GF_PATHS_CONFIG=/etc/grafana/custom/settings.ini - # - GF_PATHS_PROVISIONING=/etc/grafana/custom/provisioning - # - GF_LOG_LEVEL=WARN - # volumes: - # - ./docker/grafana/custom/settings.ini:/etc/grafana/custom/settings.ini - # - ./docker/grafana/custom/l2/provisioning/:/etc/grafana/custom/provisioning/ - # - grafana_data:/var/lib/grafana - # profiles: - # - nethermind_execution_l2 - # - prover - # - proposer + grafana: + image: grafana/grafana:latest + restart: unless-stopped + ports: + - ${PORT_GRAFANA}:${PORT_GRAFANA} + depends_on: + - nethermind_execution_l2 + - taiko_client_driver + - prometheus + environment: + - GF_PATHS_CONFIG=/etc/grafana/custom/settings.ini + - GF_PATHS_PROVISIONING=/etc/grafana/custom/provisioning + - GF_LOG_LEVEL=WARN + volumes: + - ./docker/grafana/custom/settings.ini:/etc/grafana/custom/settings.ini + - ./docker/grafana/custom/l2/provisioning/:/etc/grafana/custom/provisioning/ + - grafana_data:/var/lib/grafana + profiles: + - nethermind_execution_l2 + - prover + - proposer -# volumes: -# prometheus_data: -# grafana_data: +volumes: + prometheus_data: + grafana_data: networks: surge: diff --git a/script/start-driver.sh b/script/start-driver.sh index 8ac2492..17ff6eb 100755 --- a/script/start-driver.sh +++ b/script/start-driver.sh @@ -5,21 +5,21 @@ set -eou pipefail if [ "$DISABLE_P2P_SYNC" = "false" ]; then exec taiko-client driver \ --l1.ws "${L1_ENDPOINT_WS}" \ - --l2.ws ws://l2_execution_engine:8546 \ + --l2.ws ws://l2-nethermind-execution-client:"${L2_WS_PORT}" \ --l1.beacon "${L1_BEACON_HTTP}" \ - --l2.auth http://l2_execution_engine:8551 \ + --l2.auth http://l2-nethermind-execution-client:"${L2_ENGINE_API_PORT}" \ --taikoL1 "${TAIKO_L1_ADDRESS}" \ --taikoL2 "${TAIKO_L2_ADDRESS}" \ - --jwtSecret /data/taiko-geth/geth/jwtsecret \ + --jwtSecret /tmp/jwt/jwtsecret \ --p2p.sync \ --p2p.checkPointSyncUrl "${P2P_SYNC_URL}" else exec taiko-client driver \ --l1.ws "${L1_ENDPOINT_WS}" \ - --l2.ws ws://l2_execution_engine:8546 \ + --l2.ws ws://l2-nethermind-execution-client:"${L2_WS_PORT}" \ --l1.beacon "${L1_BEACON_HTTP}" \ - --l2.auth http://l2_execution_engine:8551 \ + --l2.auth http://l2-nethermind-execution-client:"${L2_ENGINE_API_PORT}" \ --taikoL1 "${TAIKO_L1_ADDRESS}" \ --taikoL2 "${TAIKO_L2_ADDRESS}" \ - --jwtSecret /data/taiko-geth/geth/jwtsecret + --jwtSecret /tmp/jwt/jwtsecret fi diff --git a/script/start-proposer.sh b/script/start-proposer.sh index fc5f1fd..a0fa4f2 100755 --- a/script/start-proposer.sh +++ b/script/start-proposer.sh @@ -4,14 +4,19 @@ set -eou pipefail if [ "$ENABLE_PROPOSER" = "true" ]; then ARGS="--l1.ws ${L1_ENDPOINT_WS} - --l2.http http://l2_execution_engine:8545 - --l2.auth http://l2_execution_engine:8551 + --l2.http http://l2-nethermind-execution-client:${L2_HTTP_PORT} + --l2.auth http://l2-nethermind-execution-client:${L2_ENGINE_API_PORT} --taikoL1 ${TAIKO_L1_ADDRESS} --taikoL2 ${TAIKO_L2_ADDRESS} - --taikoToken ${TAIKO_TOKEN_L1_ADDRESS} - --jwtSecret /data/taiko-geth/geth/jwtsecret + --jwtSecret /tmp/jwt/jwtsecret --l1.proposerPrivKey ${L1_PROPOSER_PRIVATE_KEY} - --l2.suggestedFeeRecipient ${L2_SUGGESTED_FEE_RECIPIENT}" + --l2.suggestedFeeRecipient ${L2_SUGGESTED_FEE_RECIPIENT} + --checkProfitability ${CHECK_PROFITABILITY} + --allowEmptyBlocks ${ALLOW_EMPTY_BLOCKS} + --surge.gasNeededForProposingBlock ${PROPOSING_BLOCK_GAS} + --surge.gasNeededForProvingBlock ${PROVING_BLOCK_GAS} + --surge.offChainCosts ${OFF_CHAIN_COSTS} + --surge.priceFluctuationModifier ${PRICE_FLUCTUATION_MODIFIER}" if [ -z "$L1_ENDPOINT_WS" ]; then echo "Error: L1_ENDPOINT_WS must be non-empty" @@ -23,6 +28,10 @@ if [ "$ENABLE_PROPOSER" = "true" ]; then exit 1 fi + if [ -n "$EPOCH_INTERVAL" ]; then + ARGS="${ARGS} --epoch.interval ${EPOCH_INTERVAL}" + fi + if [ -n "$EPOCH_MIN_TIP" ]; then ARGS="${ARGS} --epoch.minTip ${EPOCH_MIN_TIP}" fi @@ -61,8 +70,8 @@ if [ "$ENABLE_PROPOSER" = "true" ]; then ARGS="${ARGS} --tx.minTipCap ${TX_MIN_TIP_CAP}" fi - if [ -n "$TX_NOT_IN_MEMPOOL" ]; then - ARGS="${ARGS} --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL}" + if [ -n "$TX_NOT_IN_MEMPOOL_TIMEOUT" ]; then + ARGS="${ARGS} --tx.notInMempoolTimeout ${TX_NOT_IN_MEMPOOL_TIMEOUT}" fi if [ -n "$TX_NUM_CONFIRMATIONS" ]; then diff --git a/script/start-prover-relayer.sh b/script/start-prover-relayer.sh index 5aea315..912f183 100755 --- a/script/start-prover-relayer.sh +++ b/script/start-prover-relayer.sh @@ -4,19 +4,15 @@ set -eou pipefail if [ "$ENABLE_PROVER" = "true" ]; then ARGS="--l1.ws ${L1_ENDPOINT_WS} - --l2.ws ws://l2_execution_engine:8546 - --l2.http http://l2_execution_engine:8545 + --l2.ws ws://l2-nethermind-execution-client:${L2_WS_PORT} + --l2.http http://l2-nethermind-execution-client:${L2_HTTP_PORT} --taikoL1 ${TAIKO_L1_ADDRESS} --taikoL2 ${TAIKO_L2_ADDRESS} - --taikoToken ${TAIKO_TOKEN_L1_ADDRESS} --l1.proverPrivKey ${L1_PROVER_PRIVATE_KEY} --prover.capacity ${PROVER_CAPACITY} - --raiko.host ${SGX_RAIKO_HOST}" - - if [ -z "$SGX_RAIKO_HOST" ]; then - echo "Error: SGX_RAIKO_HOST must be non-empty" - exit 1 - fi + --sgxVerifier ${SGX_VERIFIER} + --sp1Verifier ${SP1_VERIFIER} + --risc0Verifier ${RISC0_VERIFIER}" if [ -z "$L1_ENDPOINT_WS" ]; then echo "Error: L1_ENDPOINT_WS must be non-empty" @@ -33,6 +29,18 @@ if [ "$ENABLE_PROVER" = "true" ]; then exit 1 fi + if [ -n "$SGX_RAIKO_HOST" ]; then + ARGS="${ARGS} --raiko.host ${SGX_RAIKO_HOST}" + fi + + if [ -n "$RAIKO_HOST_ZKVM" ]; then + ARGS="${ARGS} --raiko.host.zkvm ${RAIKO_HOST_ZKVM}" + fi + + if [ -n "$RAIKO_REQUEST_TIMEOUT" ]; then + ARGS="${ARGS} --raiko.requestTimeout ${RAIKO_REQUEST_TIMEOUT}" + fi + if [ -n "$PROVER_SET" ]; then ARGS="${ARGS} --proverSet ${PROVER_SET}" fi diff --git a/chainspec.json b/static/chainspec.json similarity index 100% rename from chainspec.json rename to static/chainspec.json diff --git a/jwtsecret b/static/jwtsecret similarity index 100% rename from jwtsecret rename to static/jwtsecret