-
Notifications
You must be signed in to change notification settings - Fork 0
Add nitro support #39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
lukeiannucci
wants to merge
10
commits into
feat-nitro
Choose a base branch
from
li/start-nitro
base: feat-nitro
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
04ffce4
start for nitro
lukeiannucci 0528932
fixes
lukeiannucci dd5a7c2
changes
lukeiannucci ba1fd18
Merge branch 'main' into li/start-nitro
lukeiannucci 8a56503
WIP
lukeiannucci 20aef14
cleanup
lukeiannucci 24822bb
cleanup
lukeiannucci 9b986e9
lint
lukeiannucci cd7379d
remove uneeded
lukeiannucci 7327808
fix startup
lukeiannucci File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,120 @@ | ||
| services: | ||
| demo-l1-network: | ||
| image: ghcr.io/espressosystems/timeboost/geth-l1:rollup-creator-round2 | ||
| command: --dev --dev.period=1 --verbosity=2 | ||
| ports: | ||
| - 8545:8545 | ||
| - 8546:8546 | ||
| espresso-dev-node: | ||
| image: ghcr.io/espressosystems/espresso-sequencer/espresso-dev-node:release-20251120-lip2p-tcp-3855 | ||
| ports: | ||
| - "41000:41000" | ||
| - "41003:41003" | ||
| - "20000:20000" | ||
| environment: | ||
| - ESPRESSO_BUILDER_PORT=41003 | ||
| - ESPRESSO_DEPLOYER_ACCOUNT_INDEX=5 | ||
| - ESPRESSO_DEV_NODE_PORT=20000 | ||
| - ESPRESSO_SEQUENCER_API_PORT=41000 | ||
| - ESPRESSO_SEQUENCER_ETH_MNEMONIC=indoor dish desk flag debris potato excuse depart ticket judge file exit | ||
| - ESPRESSO_SEQUENCER_L1_PROVIDER=http://demo-l1-network:8545 | ||
| - ESPRESSO_SEQUENCER_DATABASE_MAX_CONNECTIONS=25 | ||
| - ESPRESSO_DEV_NODE_EPOCH_HEIGHT=1000000 | ||
| - ESPRESSO_DEV_NODE_MAX_BLOCK_SIZE=10485760 | ||
| - ESPRESSO_SEQUENCER_STORAGE_PATH=/data/espresso | ||
| - RUST_LOG=WARN | ||
| - RUST_LOG_FORMAT | ||
| - ESPRESSO_DEV_NODE_VERSION=0.4 | ||
| volumes: | ||
| - espresso_storage:/data/espresso | ||
| depends_on: | ||
| demo-l1-network: | ||
| condition: service_healthy | ||
| healthcheck: | ||
| test: | ||
| [ | ||
| "CMD", | ||
| "curl", | ||
| "-s", | ||
| "-X", | ||
| "POST", | ||
| "--data", | ||
| '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}', | ||
| "-H", | ||
| "Content-Type: application/json", | ||
| "http://localhost:8545", | ||
| ] | ||
| interval: 5s | ||
| timeout: 3s | ||
| retries: 10 | ||
|
|
||
| rollup-creator: | ||
| image: ghcr.io/espressosystems/timeboost/rollup-creator:rpc | ||
| volumes: | ||
| - "config:/config" | ||
| - "./nitro-config:/nitro-config" | ||
| environment: | ||
| AUTHORIZE_VALIDATORS: 10 | ||
| CHAIN_DEPLOYMENT_INFO: "/config/deployment.json" | ||
| CHILD_CHAIN_CONFIG_PATH: "/nitro-config/l2_chain_config.json" | ||
| CHILD_CHAIN_INFO: "/config/deployed_chain_info.json" | ||
| CHILD_CHAIN_NAME: "arb-dev-test" | ||
| DEPLOYER_PRIVKEY: 0x4f3edf983ac636a65a842ce7c78d9aa706d3b113b37f60c1b6d9d1f0a5b2b5ff | ||
| MAX_DATA_SIZE: 117964 | ||
| OWNER_ADDRESS: 0x3f1Eae7D46d88F08fc2F8ed27FCb2AB183EB2d0E | ||
| PARENT_CHAIN_ID: 1337 | ||
| PARENT_CHAIN_RPC: "http://demo-l1-network:8545" | ||
| SEQUENCER_ADDRESS: 0x2F1eAe7Dd46D88f08fC2f8ED27Fcb2Ab183eb2d0 | ||
| WASM_MODULE_ROOT: 0xdb698a2576298f25448bc092e52cf13b1e24141c997135d70f217d674bbeb69a | ||
| command: ["create-rollup-testnode"] | ||
| depends_on: | ||
| demo-l1-network: | ||
| condition: service_healthy | ||
|
|
||
| nitro: | ||
| image: ghcr.io/espressosystems/nitro-espresso-integration/nitro-node:integration-v3.9.8 | ||
| entrypoint: /usr/local/bin/nitro | ||
| ports: | ||
| - "8547:8547" | ||
| - "8548:8548" | ||
| - "9642:9642" | ||
| volumes: | ||
| - "nitro:/home/user/.arbitrum/local/nitro" | ||
| - "l1keystore:/home/user/l1keystore" | ||
| - "config:/config" | ||
| - "./nitro-config:/nitro-config" | ||
| command: | ||
| - --conf.file=/nitro-config/nitro_config.json | ||
| - --node.feed.output.enable | ||
| - --node.feed.output.port=9642 | ||
| - --http.api=net,web3,eth,txpool,debug,timeboost,auctioneer,batcher | ||
| - --node.seq-coordinator.my-url=http://nitro:8547 | ||
| - --graphql.enable | ||
| - --graphql.vhosts=* | ||
| - --graphql.corsdomain=* | ||
| depends_on: | ||
| rollup-creator: | ||
| condition: service_completed_successfully | ||
| healthcheck: | ||
| test: | ||
| [ | ||
| "CMD", | ||
| "curl", | ||
| "-s", | ||
| "-X", | ||
| "POST", | ||
| "--data", | ||
| '{\"jsonrpc\":\"2.0\",\"method\":\"eth_blockNumber\",\"params\":[],\"id\":1}', | ||
| "-H", | ||
| "Content-Type: application/json", | ||
| "http://localhost:8547", | ||
| ] | ||
| interval: 5s | ||
| timeout: 3s | ||
| retries: 12 | ||
|
|
||
| volumes: | ||
| config: | ||
| l1keystore: | ||
| espresso_storage: | ||
| nitro: | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| { | ||
| "chainId": 412346, | ||
| "homesteadBlock": 0, | ||
| "daoForkSupport": true, | ||
| "eip150Block": 0, | ||
| "eip150Hash": "0x0000000000000000000000000000000000000000000000000000000000000000", | ||
| "eip155Block": 0, | ||
| "eip158Block": 0, | ||
| "byzantiumBlock": 0, | ||
| "constantinopleBlock": 0, | ||
| "petersburgBlock": 0, | ||
| "istanbulBlock": 0, | ||
| "muirGlacierBlock": 0, | ||
| "berlinBlock": 0, | ||
| "londonBlock": 0, | ||
| "clique": { | ||
| "period": 0, | ||
| "epoch": 0 | ||
| }, | ||
| "alloc": { | ||
| "0x3f1eae7d46d88f08fc2f8ed27fcb2ab183eb2d0e": { | ||
| "balance": "0x21e19e0c9bab2400000" | ||
| } | ||
| }, | ||
| "arbitrum": { | ||
| "EnableArbOS": true, | ||
| "AllowDebugPrecompiles": true, | ||
| "DataAvailabilityCommittee": false, | ||
| "InitialArbOSVersion": 40, | ||
| "InitialChainOwner": "0x3f1eae7d46d88f08fc2f8ed27fcb2ab183eb2d0e", | ||
| "GenesisBlockNum": 0 | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,141 @@ | ||
| { | ||
| "ensure-rollup-deployment": false, | ||
| "parent-chain": { | ||
| "connection": { | ||
| "url": "ws://demo-l1-network:8546" | ||
| } | ||
| }, | ||
| "chain": { | ||
| "id": 412346, | ||
| "info-files": [ | ||
| "/config/deployed_chain_info.json" | ||
| ] | ||
| }, | ||
| "node": { | ||
| "staker": { | ||
| "dangerous": { | ||
| "without-block-validator": false | ||
| }, | ||
| "parent-chain-wallet": { | ||
| "account": "0x6A568afe0f82d34759347bb36F14A6bB171d2CBe", | ||
| "password": "passphrase", | ||
| "pathname": "/home/user/l1keystore" | ||
| }, | ||
| "disable-challenge": false, | ||
| "enable": false, | ||
| "staker-interval": "10s", | ||
| "make-assertion-interval": "10s", | ||
| "strategy": "MakeNodes" | ||
| }, | ||
| "sequencer": true, | ||
| "dangerous": { | ||
| "no-sequencer-coordinator": true, | ||
| "disable-blob-reader": true | ||
| }, | ||
| "delayed-sequencer": { | ||
| "enable": true | ||
| }, | ||
| "seq-coordinator": { | ||
| "enable": false, | ||
| "redis-url": "redis://redis:6379", | ||
| "lockout-duration": "30s", | ||
| "lockout-spare": "1s", | ||
| "my-url": "", | ||
| "retry-interval": "0.5s", | ||
| "seq-num-duration": "24h0m0s", | ||
| "update-interval": "3s" | ||
| }, | ||
| "batch-poster": { | ||
| "enable": true, | ||
| "max-delay": "1m", | ||
| "l1-block-bound": "ignore", | ||
| "parent-chain-wallet": { | ||
| "private-key": "4f3edf983ac636a65a842ce7c78d9aa706d3b113b37f60c1b6d9d1f0a5b2b5ff" | ||
| }, | ||
| "data-poster": { | ||
| "redis-signer": { | ||
| "signing-key": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" | ||
| }, | ||
| "wait-for-l1-finality": false, | ||
| "replacement-times": [ | ||
| "5s", | ||
| "10s", | ||
| "20s" | ||
| ] | ||
| }, | ||
| "poll-interval": "10s" | ||
| }, | ||
| "espresso": { | ||
| "batch-poster": { | ||
| "hotshot-first-posting-block": 0, | ||
| "hotshot-url": "http://espresso-dev-node:41000", | ||
| "resubmit-espresso-tx-deadline": "2m", | ||
| "tee-type": "SGX", | ||
| "txns-monitoring-interval": "1s" | ||
| }, | ||
| "streamer": { | ||
| "txns-polling-interval": "1s" | ||
| } | ||
| }, | ||
| "block-validator": { | ||
| "validation-server": { | ||
| "url": "ws://validation_node:8549", | ||
| "jwtsecret": "/config/val_jwt.hex" | ||
| } | ||
| }, | ||
| "feed": { | ||
| "input": { | ||
| "url": [] | ||
| }, | ||
| "output": { | ||
| "enable": true, | ||
| "signed": false, | ||
| "addr": "0.0.0.0", | ||
| "port": 9642 | ||
| } | ||
| }, | ||
| "data-availability": { | ||
| "enable": false, | ||
| "rpc-aggregator": { | ||
| "enable": false, | ||
| "assumed-honest": 1, | ||
| "backends": [ | ||
| { | ||
| "url": "http://das-committee-a:9876", | ||
| "pubkey": "" | ||
| }, | ||
| { | ||
| "url": "http://das-committee-b:9876", | ||
| "pubkey": "" | ||
| } | ||
| ] | ||
| }, | ||
| "rest-aggregator": { | ||
| "enable": true, | ||
| "urls": [ | ||
| "http://das-mirror:9877" | ||
| ] | ||
| }, | ||
| "parent-chain-node-url": "ws://geth:8546", | ||
|
lukeiannucci marked this conversation as resolved.
Outdated
|
||
| "sequencer-inbox-address": "0x6be3f7c539009f9b3ae2ce11e231bf064c081cd9" | ||
| } | ||
| }, | ||
| "execution": { | ||
| "sequencer": { | ||
| "enable": false | ||
| }, | ||
| "forwarding-target": "null" | ||
| }, | ||
| "persistent": { | ||
| "chain": "local" | ||
| }, | ||
| "ws": { | ||
| "addr": "0.0.0.0" | ||
| }, | ||
| "http": { | ||
| "addr": "0.0.0.0", | ||
| "vhosts": "*", | ||
| "corsdomain": "*" | ||
| }, | ||
| "log-level": "INFO" | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| package main | ||
|
|
||
| import ( | ||
| "context" | ||
| "math/big" | ||
|
|
||
| opStreamer "github.com/EspressoSystems/espresso-streamers/op" | ||
| "github.com/ethereum/go-ethereum/accounts/abi/bind" | ||
| ) | ||
|
|
||
| const finalizedBlocks = 500 | ||
|
|
||
| // mockLightClient implements opStreamer.LightClientCallerInterface for dev/test | ||
| // environments where the real light client contract is not available. | ||
| // It tracks the live Espresso head and returns a height lagged by finalizedBlocks. | ||
| type mockLightClient struct { | ||
| client opStreamer.EspressoClient | ||
| last uint64 | ||
| } | ||
|
|
||
| var _ opStreamer.LightClientCallerInterface = (*mockLightClient)(nil) | ||
|
|
||
| func newMockLightClient(client opStreamer.EspressoClient) *mockLightClient { | ||
| return &mockLightClient{client: client} | ||
| } | ||
|
|
||
| func (m *mockLightClient) FinalizedState(_ *bind.CallOpts) (opStreamer.FinalizedState, error) { | ||
| current, err := m.client.FetchLatestBlockHeight(context.Background()) | ||
| result := m.last | ||
| if err == nil { | ||
| m.last = 0 | ||
| if current > finalizedBlocks { | ||
| m.last = current - finalizedBlocks | ||
| } | ||
| } | ||
| return opStreamer.FinalizedState{ | ||
| BlockHeight: result, | ||
| ViewNum: 0, | ||
| BlockCommRoot: big.NewInt(0), | ||
| }, nil | ||
| } | ||
|
lukeiannucci marked this conversation as resolved.
Outdated
|
||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why are we using timeboost image?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this was a prebuilt l1 image we used for timeboost. i will move away from this.