Skip to content

Commit

Permalink
anytrust fallback local test
Browse files Browse the repository at this point in the history
  • Loading branch information
Ferret-san committed Dec 2, 2024
2 parents 02621d2 + df7d16e commit 9cfbe1d
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 15 deletions.
8 changes: 8 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,8 @@ services:
- "config:/config"
- "tokenbridge-data:/tokenbridge-data"
command: --conf.file /config/sequencer_config.json --node.feed.output.enable --node.feed.output.port 9642 --http.api net,web3,eth,txpool,debug --node.seq-coordinator.my-url ws://sequencer:8548 --graphql.enable --graphql.vhosts * --graphql.corsdomain *
extra_hosts:
- "host.docker.internal:host-gateway"
depends_on:
- geth

Expand Down Expand Up @@ -245,6 +247,8 @@ services:
- "l1keystore:/home/user/l1keystore"
- "config:/config"
command: --conf.file /config/poster_config.json
extra_hosts:
- "host.docker.internal:host-gateway"
depends_on:
- geth
- redis
Expand Down Expand Up @@ -293,6 +297,8 @@ services:
- "l1keystore:/home/user/l1keystore"
- "config:/config"
command: --conf.file /config/validator_config.json --http.port 8547 --http.api net,web3,arb,debug --ws.port 8548
extra_hosts:
- "host.docker.internal:host-gateway"
depends_on:
- sequencer
- validation_node
Expand Down Expand Up @@ -322,6 +328,8 @@ services:
volumes:
- "config:/config"
command: --conf.file /config/validation_node_config.json
extra_hosts:
- "host.docker.internal:host-gateway"

scripts:
build: scripts/
Expand Down
7 changes: 4 additions & 3 deletions rollupcreator/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
FROM node:18-bullseye-slim
ARG NITRO_CONTRACTS_BRANCH=main
ARG NITRO_CONTRACTS_BRANCH=celestia-v3.1.0-test
RUN apt-get update && \
apt-get install -y git docker.io python3 build-essential curl jq
WORKDIR /workspace
RUN git clone --no-checkout https://github.com/OffchainLabs/nitro-contracts.git ./
WORKDIR /workspace
RUN git clone --recurse-submodules --no-checkout https://github.com/celestiaorg/nitro-contracts.git ./
RUN git checkout ${NITRO_CONTRACTS_BRANCH}
RUN curl -L https://foundry.paradigm.xyz | bash
ENV PATH="${PATH}:/root/.foundry/bin"
RUN foundryup
RUN forge update lib/forge-std
RUN touch scripts/config.ts
RUN yarn install
RUN yarn build:all
Expand Down
23 changes: 14 additions & 9 deletions scripts/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ function writeConfigs(argv: any) {
"dangerous": {
"without-block-validator": false
},
"parent-chain-wallet" : {
"parent-chain-wallet": {
"account": namedAddress("validator"),
"password": consts.l1passphrase,
"pathname": consts.l1keystore,
Expand Down Expand Up @@ -225,7 +225,7 @@ function writeConfigs(argv: any) {
"redis-url": argv.redisUrl,
"max-delay": "30s",
"l1-block-bound": "ignore",
"parent-chain-wallet" : {
"parent-chain-wallet": {
"account": namedAddress("sequencer"),
"password": consts.l1passphrase,
"pathname": consts.l1keystore,
Expand Down Expand Up @@ -253,7 +253,12 @@ function writeConfigs(argv: any) {
// TODO Fix das config to not need this redundant config
"parent-chain-node-url": argv.l1url,
"sequencer-inbox-address": "not_set"
}
},
"celestia-cfg": {
"enable": true,
"url": "http://host.docker.internal:9875"
},
"da-preference": ["celestia", "anytrust"]
},
"execution": {
"sequencer": {
Expand Down Expand Up @@ -519,9 +524,9 @@ export const writeConfigCommand = {
describe: "writes config files",
builder: {
simple: {
boolean: true,
describe: "simple config (sequencer is also poster, validator)",
default: false,
boolean: true,
describe: "simple config (sequencer is also poster, validator)",
default: false,
},
anytrust: {
boolean: true,
Expand All @@ -539,7 +544,7 @@ export const writeConfigCommand = {
default: ""
},

},
},
handler: (argv: any) => {
writeConfigs(argv)
}
Expand Down Expand Up @@ -615,8 +620,8 @@ export const writeL2DASKeysetConfigCommand = {
describe: "DAS committee member B BLS pub key",
default: ""
},
},
},
handler: (argv: any) => {
writeL2DASKeysetConfig(argv)
writeL2DASKeysetConfig(argv)
}
}
5 changes: 3 additions & 2 deletions test-node.bash
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ set -eu
NITRO_NODE_VERSION=offchainlabs/nitro-node:v3.2.1-d81324d-dev
BLOCKSCOUT_VERSION=offchainlabs/blockscout:v1.1.0-0e716c8

# This commit matches v2.1.0 release of nitro-contracts, with additional support to set arb owner through upgrade executor
DEFAULT_NITRO_CONTRACTS_VERSION="99c07a7db2fcce75b751c5a2bd4936e898cda065"
# This commit matches the v1.2.1 contracts, with additional support for CacheManger deployment.
# Once v1.2.2 is released, we can switch to that version.
DEFAULT_NITRO_CONTRACTS_VERSION="8e5836b8c39657d27a6c7ef69e658720b34b6fb8"
DEFAULT_TOKEN_BRIDGE_VERSION="v1.2.2"

# Set default versions if not overriden by provided env vars
Expand Down
2 changes: 1 addition & 1 deletion tokenbridge/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM node:18-bullseye-slim
ARG TOKEN_BRIDGE_BRANCH=main
RUN apt-get update && \
apt-get install -y git docker.io python3 build-essential
WORKDIR /workspace
WORKDIR /workspace
RUN git clone --no-checkout https://github.com/OffchainLabs/token-bridge-contracts.git ./
RUN git checkout ${TOKEN_BRIDGE_BRANCH}
RUN yarn install
Expand Down

0 comments on commit 9cfbe1d

Please sign in to comment.