Skip to content
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

revert mapper changes #3

Closed
wants to merge 47 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
a4b0ccd
test.sh: fix typo (#670)
onbjerg Jan 12, 2023
c2b81df
go.work: disable top-level go.work by default
fjl Jan 23, 2023
e2595c8
simulators/ethereum/engine: adding tests for Shanghai (#676)
fjl Jan 23, 2023
e491cf8
clients/nethermind: add Shanghai fork timestamp
fjl Jan 23, 2023
3e7d20c
clients/go-ethereum: add Shanghai for timestamp
fjl Jan 23, 2023
1084506
clients/erigon: add Shanghai fork timestamp
fjl Jan 23, 2023
3fd0a5d
simulators/ethereum/engine: fix nil pointer exception (#678)
marioevz Jan 23, 2023
4fcdc0d
clients/ethereumjs: fix build and add Shanghai fork configuration (#679)
marioevz Jan 23, 2023
104c185
clients/besu: add Shanghai fork and fix issue with duplicated node ke…
gfukushima Jan 23, 2023
f15fbd4
simulators/eth2: add common library and tests for withdrawals (#681)
fjl Jan 23, 2023
2c75c1a
clients/lodestar: new beacon node and validator client definition (#680)
marioevz Jan 23, 2023
a3a455a
simulators/eth2/withdrawals: rename suite
fjl Jan 23, 2023
5b56192
simulators/eth2/common: avoid <nil> value for HIVE_SHANGHAI_TIMESTAMP
fjl Jan 24, 2023
316abea
simulators/eth2/withdrawals: clean up go.mod
fjl Jan 24, 2023
a49efd5
simulators/eth2/testnet: clean up go.mod
fjl Jan 24, 2023
8862124
simulators/eth2/engine: clean up go.mod
fjl Jan 24, 2023
3ffb4ee
simulators/eth2: go mod tidy
fjl Jan 24, 2023
ce0da5b
simulators/ethereum/engine: set HIVE_MERGE_BLOCK_ID before shanghai f…
fjl Jan 24, 2023
9a6033b
README.md, docs: fix typos in documentation (#683)
omahs Jan 24, 2023
415d855
simulators/eth2/common: handle client branch when getting validator name
fjl Jan 24, 2023
abdaeff
clients/nethermind: add shanghai EIPs to mapper (#686)
marioevz Jan 24, 2023
ef7bb9c
simulators/eth2/withdrawals: check exact partial withdrawn balance ex…
marioevz Jan 24, 2023
289b8f3
clients/nethermind: use terminal block hash/number in config (#687)
marioevz Jan 25, 2023
6295612
hivesim: make test matching case insensitive (#689)
fjl Jan 25, 2023
7184544
simulators/eth2/withdrawals: handle missed slots in test (#690)
marioevz Jan 25, 2023
d8dfa0d
simulators/ethereum/engine: Remove PoW config from withdrawals (#691)
marioevz Jan 25, 2023
e4b8623
clients/nimbus: fix nimbus (#693)
marioevz Jan 27, 2023
380c6c9
simulators/eth2: support 12 second slots, add test for large withdraw…
marioevz Jan 27, 2023
88640e0
cmd/hiveview: viewer app update (#696)
fjl Jan 28, 2023
63dee08
simulators/ethereum/consensus: update for Shanghai
fjl Jan 28, 2023
54737f0
cmd/hiveview: fix hourglass in Safari
fjl Jan 28, 2023
b8fc30b
simulators/ethereum/graphql: align tests with current spec (#692)
shemnon Jan 28, 2023
01175e0
cmd/hiveview: responsive layout for table views (#697)
fjl Feb 1, 2023
fa8d62c
simulators/ethereum/engine: INVALID_BLOCK_HASH is deprecated in Shan…
yperbasis Feb 1, 2023
7068ab4
simulators/ethereum/engine: tests for getPayloadBodies*, exchangeCapa…
marioevz Feb 2, 2023
52fbfc3
cmd/hiveview: small UI improvements (#701)
fjl Feb 2, 2023
be72423
cmd/hiveview: fixing more stuff in the UI (#702)
fjl Feb 2, 2023
cbbe48f
cmd/hiveview: print listing generator errors in -serve mode
fjl Feb 6, 2023
97557e8
cmd/hiveview: skip hive.json
fjl Feb 6, 2023
84c255d
cmd/hiveview: hide client list in details box when test has no clients
fjl Feb 6, 2023
97d9b7b
simulators/ethereum/engine: increase tests coverage (#700)
marioevz Feb 6, 2023
e4ef5d9
README.md: update description of hivetests2 server
fjl Feb 6, 2023
bf45c94
docs: add info about ethereum/engine simulator
fjl Feb 6, 2023
603391a
docs: remove accidental \
fjl Feb 6, 2023
33224ab
cmd/hiveview: UI improvements (#705)
fjl Feb 6, 2023
a0a57f2
feat: reth (#1)
gakonst Feb 17, 2023
ce6efbd
revert mapper changes
Rjected Feb 16, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Ethereum Foundation maintains two public Hive instances to check for consensus,
blockchain compatibility:

- eth1 consensus, rpc, p2p tests are on <https://hivetests.ethdevops.io>
- 'merge' testing runs on <https://hivetests2.ethdevops.io>
- Engine API integration tests are on <https://hivetests2.ethdevops.io>

**To read more about hive, please check [the documentation][doc].**

Expand All @@ -19,9 +19,9 @@ for validating Ethereum client implementations.
- go-ethereum:
- Genesis chain config couldn't handle present but empty settings: [#2790](https://github.com/ethereum/go-ethereum/pull/2790)
- Data race between remote block import and local block mining: [#2793](https://github.com/ethereum/go-ethereum/pull/2793)
- Downloader didn't penalize incompatible forks hashly enough: [#2801](https://github.com/ethereum/go-ethereum/pull/2801)
- Downloader didn't penalize incompatible forks harshly enough: [#2801](https://github.com/ethereum/go-ethereum/pull/2801)
- Nethermind:
- Bug in p2p whith bonding nodes algorithm found by Hive: [#1894](https://github.com/NethermindEth/nethermind/pull/1894)
- Bug in p2p with bonding nodes algorithm found by Hive: [#1894](https://github.com/NethermindEth/nethermind/pull/1894)
- Difference in return value for 'r' parameter in getTransactionByHash: [#2372](https://github.com/NethermindEth/nethermind/issues/2372)
- CREATE/CREATE2 behavior when account already has max nonce [#3698](https://github.com/NethermindEth/nethermind/pull/3698)
- Blake2 performance issue with non-vectorized code [#3837](https://github.com/NethermindEth/nethermind/pull/3837)
Expand All @@ -36,7 +36,7 @@ We follow the [Collective Code Construction Contract (C4)][c4], code contributio
as expanded and explained in [The ZeroMQ Process][zmq-process]. The core idea being that
any patch that successfully solves an issue (bug/feature) and doesn't break any existing
code/contracts must be optimistically merged by maintainers. Followup patches may be used
to for additional polishes – and patches may even be outright reverted if they turn out to
for additional polishes – and patches may even be outright reverted if they turn out to
have a negative impact – but no change must be rejected based on personal values.

### License
Expand Down
17 changes: 9 additions & 8 deletions clients/besu/besu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -99,14 +99,15 @@ if [ -d /blocks ]; then
IMPORTFLAGS="$IMPORTFLAGS $blocks"
fi


# Configure mining.
if [ "$HIVE_MINER" != "" ]; then
FLAGS="$FLAGS --miner-enabled --miner-coinbase=$HIVE_MINER"
# For clique mining, besu uses the node key as the block signing key.
if [ "$HIVE_CLIQUE_PRIVATEKEY" != "" ]; then
echo "Importing clique signing key as node key..."
echo "$HIVE_CLIQUE_PRIVATEKEY" > /opt/besu/key
if [ "$HIVE_BOOTNODE" != "" ]; then
# Configure mining.
if [ "$HIVE_MINER" != "" ]; then
FLAGS="$FLAGS --miner-enabled --miner-coinbase=$HIVE_MINER"
# For clique mining, besu uses the node key as the block signing key.
if [ "$HIVE_CLIQUE_PRIVATEKEY" != "" ]; then
echo "Importing clique signing key as node key..."
echo "$HIVE_CLIQUE_PRIVATEKEY" > /opt/besu/key
fi
fi
fi
if [ "$HIVE_MINER_EXTRA" != "" ]; then
Expand Down
1 change: 1 addition & 0 deletions clients/besu/mapper.jq
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ def to_int:
"berlinBlock": env.HIVE_FORK_BERLIN|to_int,
"londonBlock": env.HIVE_FORK_LONDON|to_int,
"parisBlock": env.HIVE_MERGE_BLOCK_ID|to_int,
"shanghaiTime": env.HIVE_SHANGHAI_TIMESTAMP|to_int,
"terminalTotalDifficulty": env.HIVE_TERMINAL_TOTAL_DIFFICULTY|to_int,
}|remove_empty
}
1 change: 1 addition & 0 deletions clients/erigon/mapper.jq
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,6 @@ def to_bool:
"berlinBlock": env.HIVE_FORK_BERLIN|to_int,
"londonBlock": env.HIVE_FORK_LONDON|to_int,
"terminalTotalDifficulty": env.HIVE_TERMINAL_TOTAL_DIFFICULTY|to_int,
"shanghaiTime": env.HIVE_SHANGHAI_TIMESTAMP|to_int,
}|remove_empty
}
2 changes: 1 addition & 1 deletion clients/ethereumjs/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FROM node:16-alpine as build
RUN apk update && apk add --no-cache bash git jq curl && rm -rf /var/cache/apk/*
RUN apk update && apk add --no-cache bash git jq curl python3 gcc make g++ && rm -rf /var/cache/apk/*
RUN git clone --depth 1 https://github.com/ethereumjs/ethereumjs-monorepo.git && \
(cd ethereumjs-monorepo && npm i)

Expand Down
2 changes: 1 addition & 1 deletion clients/ethereumjs/ethereumjs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
set -e

ethereumjs="node /ethereumjs-monorepo/packages/client/dist/bin/cli.js"
FLAGS="--gethGenesis ./genesis.json --rpc --rpcEngine --saveReceipts --rpcEnginePort 8551 --ws --loglevel debug"
FLAGS="--gethGenesis ./genesis.json --rpc --rpcEngine --saveReceipts --rpcEnginePort 8551 --ws --logLevel debug"


# Configure the chain.
Expand Down
1 change: 1 addition & 0 deletions clients/ethereumjs/mapper.jq
Original file line number Diff line number Diff line change
Expand Up @@ -55,5 +55,6 @@ def to_bool:
"londonBlock": env.HIVE_FORK_LONDON|to_int,
"mergeForkBlock": env.HIVE_MERGE_BLOCK_ID|to_int,
"terminalTotalDifficulty": env.HIVE_TERMINAL_TOTAL_DIFFICULTY|to_int,
"shanghaiTime": env.HIVE_SHANGHAI_TIMESTAMP|to_int,
}|remove_empty
}
1 change: 1 addition & 0 deletions clients/go-ethereum/mapper.jq
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,6 @@ def to_bool:
"londonBlock": env.HIVE_FORK_LONDON|to_int,
"mergeForkBlock": env.HIVE_MERGE_BLOCK_ID|to_int,
"terminalTotalDifficulty": env.HIVE_TERMINAL_TOTAL_DIFFICULTY|to_int,
"shanghaiTime": env.HIVE_SHANGHAI_TIMESTAMP|to_int,
}|remove_empty
}
10 changes: 10 additions & 0 deletions clients/lodestar-bn/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
ARG branch=next

FROM chainsafe/lodestar:$branch

ADD lodestar_bn.sh /lodestar_bn.sh
RUN chmod +x /lodestar_bn.sh

RUN node /usr/app/node_modules/.bin/lodestar --version | grep "Version:.*" | grep -o "v.*" > /version.txt

ENTRYPOINT ["/lodestar_bn.sh"]
4 changes: 4 additions & 0 deletions clients/lodestar-bn/hive.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
roles:
- beacon
build_targets:
- mainnet
70 changes: 70 additions & 0 deletions clients/lodestar-bn/lodestar_bn.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
#!/bin/sh

# Immediately abort the script on any error encountered
set -e

if [ ! -f "/hive/input/genesis.ssz" ]; then
if [ -z "$HIVE_ETH2_ETH1_RPC_ADDRS" ]; then
echo "genesis.ssz file is missing, and no Eth1 RPC addr was provided for building genesis from scratch."
# TODO: alternative to start from weak-subjectivity-state
exit 1
fi
fi

mkdir -p /data/testnet_setup


# empty bootnodes file, required for custom testnet setup, use CLI arg instead to configure it.

echo "${HIVE_ETH2_CONFIG_DEPOSIT_CONTRACT_ADDRESS:-0x1111111111111111111111111111111111111111}" > /data/testnet_setup/deposit_contract.txt

mkdir -p /data/beacon
mkdir -p /data/network

case "$HIVE_LOGLEVEL" in
0|1) LOG=error ;;
2) LOG=warn ;;
3) LOG=info ;;
4) LOG=debug ;;
5) LOG=silly ;;
esac
LOG=debug

echo "bootnodes: ${HIVE_ETH2_BOOTNODE_ENRS}"

CONTAINER_IP=`hostname -i | awk '{print $1;}'`
echo Container IP: $CONTAINER_IP
bootnodes_option=$([[ "$HIVE_ETH2_BOOTNODE_ENRS" == "" ]] && echo "" || echo "--bootnodes ${HIVE_ETH2_BOOTNODE_ENRS//,/ }")
metrics_option=$([[ "$HIVE_ETH2_METRICS_PORT" == "" ]] && echo "" || echo "--metrics --metrics.address=$CONTAINER_IP --metrics.port=$HIVE_ETH2_METRICS_PORT")

echo "bootnodes option : ${bootnodes_option}"

echo -n "0x7365637265747365637265747365637265747365637265747365637265747365" > /jwtsecret

echo Starting Lodestar Beacon Node

node /usr/app/node_modules/.bin/lodestar \
beacon \
--logLevel="$LOG" \
--dataDir=/data/beacon \
--port="${HIVE_ETH2_P2P_TCP_PORT:-9000}" \
--discoveryPort="${HIVE_ETH2_P2P_UDP_PORT:-9000}" \
--paramsFile=/hive/input/config.yaml \
--genesisStateFile=/hive/input/genesis.ssz \
--rest \
--rest.namespace="*" \
--rest.address=0.0.0.0 \
--rest.port="${HIVE_ETH2_BN_API_PORT:-4000}" \
--eth1 \
--execution.urls="$HIVE_ETH2_ETH1_ENGINE_RPC_ADDRS" \
--eth1.depositContractDeployBlock=${HIVE_ETH2_DEPOSIT_DEPLOY_BLOCK_NUMBER:-0} \
--jwt-secret=/jwtsecret \
$metrics_option \
$bootnodes_option \
--enr.ip="${CONTAINER_IP}" \
--enr.tcp="${HIVE_ETH2_P2P_TCP_PORT:-9000}" \
--enr.udp="${HIVE_ETH2_P2P_UDP_PORT:-9000}" \
--network.connectToDiscv5Bootnodes=true \
--discv5 \
--subscribeAllSubnets=true \
--targetPeers="${HIVE_ETH2_P2P_TARGET_PEERS:-10}"
10 changes: 10 additions & 0 deletions clients/lodestar-vc/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
ARG branch=next

FROM chainsafe/lodestar:$branch

ADD lodestar_vc.sh /lodestar_vc.sh
RUN chmod +x /lodestar_vc.sh

RUN node /usr/app/node_modules/.bin/lodestar --version | grep "Version:.*" | grep -o "v.*" > /version.txt

ENTRYPOINT ["/lodestar_vc.sh"]
2 changes: 2 additions & 0 deletions clients/lodestar-vc/hive.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
roles:
- validator
46 changes: 46 additions & 0 deletions clients/lodestar-vc/lodestar_vc.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
#!/bin/sh

# Immediately abort the script on any error encountered
set -e

mkdir -p /data/testnet_setup
mkdir -p /data/vc
mkdir -p /data/validators
mkdir -p /data/secrets

cp /hive/input/config.yaml /data/testnet_setup

echo "${HIVE_ETH2_CONFIG_DEPOSIT_CONTRACT_ADDRESS:-0x1111111111111111111111111111111111111111}" > /data/testnet_setup/deposit_contract.txt
echo "${HIVE_ETH2_DEPOSIT_DEPLOY_BLOCK_NUMBER:-0}" > /data/testnet_setup/deploy_block.txt

for keystore_path in /hive/input/keystores/*
do
pubkey=$(basename "$keystore_path")
mkdir "/data/validators/$pubkey"
cp "/hive/input/keystores/$pubkey/keystore.json" "/data/validators/$pubkey/voting-keystore.json"
cp "/hive/input/secrets/$pubkey" "/data/secrets/$pubkey"
done

metrics_option=$([[ "$HIVE_ETH2_METRICS_PORT" == "" ]] && echo "" || echo "--metrics --metrics.address=$CONTAINER_IP --metrics.port=$HIVE_ETH2_METRICS_PORT")

LOG=info
case "$HIVE_LOGLEVEL" in
0|1) LOG=error ;;
2) LOG=warn ;;
3) LOG=info ;;
4) LOG=debug ;;
5) LOG=trace ;;
esac

echo Starting Lodestar Validator Client

node /usr/app/node_modules/.bin/lodestar \
validator \
--logLevel="$LOG" \
--dataDir=/data/vc \
--paramsFile=/hive/input/config.yaml \
--keystoresDir="/data/validators" \
--secretsDir="/data/secrets" \
$metrics_option \
--beaconNodes="http://$HIVE_ETH2_BN_API_IP:$HIVE_ETH2_BN_API_PORT"

6 changes: 6 additions & 0 deletions clients/nethermind/mapper.jq
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,12 @@ def clique_engine:
# Merge
"MergeForkIdTransition": env.HIVE_MERGE_BLOCK_ID|to_hex,

# Shanghai
"eip3651TransitionTimestamp": env.HIVE_SHANGHAI_TIMESTAMP|to_hex,
"eip3855TransitionTimestamp": env.HIVE_SHANGHAI_TIMESTAMP|to_hex,
"eip3860TransitionTimestamp": env.HIVE_SHANGHAI_TIMESTAMP|to_hex,
"eip4895TransitionTimestamp": env.HIVE_SHANGHAI_TIMESTAMP|to_hex,

# Other chain parameters
"networkID": env.HIVE_NETWORK_ID|to_hex,
"chainID": env.HIVE_CHAIN_ID|to_hex,
Expand Down
4 changes: 3 additions & 1 deletion clients/nethermind/mkconfig.jq
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ def merge_config:
"Merge": {
"Enabled": true,
"TerminalTotalDifficulty": env.HIVE_TERMINAL_TOTAL_DIFFICULTY,
}
"TerminalBlockHash": env.HIVE_TERMINAL_BLOCK_HASH,
"TerminalBlockNumber": env.HIVE_TERMINAL_BLOCK_NUMBER,
} | remove_empty
}
else
{}
Expand Down
9 changes: 5 additions & 4 deletions clients/nimbus-bn/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ ENV NPROC=2

RUN git clone --depth 1 --branch unstable https://github.com/status-im/nimbus-eth2.git \
&& cd nimbus-eth2 \
&& make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC} -d:SECONDS_PER_SLOT=6" V=1 update
&& make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC}" V=1 update

RUN cd nimbus-eth2 && \
make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC} -d:SECONDS_PER_SLOT=6" nimbus_beacon_node && \
make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC}" nimbus_beacon_node && \
mv build/nimbus_beacon_node /usr/bin/

# --------------------------------- #
Expand All @@ -34,9 +34,10 @@ RUN usr/bin/nimbus_beacon_node --version > /version.txt

ADD nimbus_bn.sh /nimbus_bn.sh
RUN chmod +x /nimbus_bn.sh
ADD nimbus_version.sh /nimbus_version.sh
RUN chmod +x /nimbus_version.sh

# TODO: output accurate client version
RUN usr/bin/nimbus_beacon_node --version > /version.txt
RUN /nimbus_version.sh > /version.txt

EXPOSE 9000 9000/udp 4000 4000/udp

Expand Down
12 changes: 4 additions & 8 deletions clients/nimbus-bn/nimbus_bn.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,15 @@ cp /hive/input/config.yaml /data/testnet_setup
# znrt encodes the values of these items between double quotes (""), which is against the spec:
# https://github.com/ethereum/consensus-specs/blob/v1.1.10/configs/mainnet.yaml
# Nimbus is the only client that complains about this.
sed -i 's/TERMINAL_TOTAL_DIFFICULTY: "\([[:digit:]]\+\)"/TERMINAL_TOTAL_DIFFICULTY: \1/' /data/testnet_setup/config.yaml
sed -i 's/TERMINAL_BLOCK_HASH: "\(0x[[:xdigit:]]\+\)"/TERMINAL_BLOCK_HASH: \1/' /data/testnet_setup/config.yaml
sed -i 's/GENESIS_FORK_VERSION: "\(0x[[:xdigit:]]\+\)"/GENESIS_FORK_VERSION: \1/' /data/testnet_setup/config.yaml
sed -i 's/ALTAIR_FORK_VERSION: "\(0x[[:xdigit:]]\+\)"/ALTAIR_FORK_VERSION: \1/' /data/testnet_setup/config.yaml
sed -i 's/BELLATRIX_FORK_VERSION: "\(0x[[:xdigit:]]\+\)"/BELLATRIX_FORK_VERSION: \1/' /data/testnet_setup/config.yaml
sed -i 's/CAPELLA_FORK_VERSION: "\(0x[[:xdigit:]]\+\)"/CAPELLA_FORK_VERSION: \1/' /data/testnet_setup/config.yaml
sed -i 's/SHARDING_FORK_VERSION: "\(0x[[:xdigit:]]\+\)"/SHARDING_FORK_VERSION: \1/' /data/testnet_setup/config.yaml
sed -i 's/"//g' /data/testnet_setup/config.yaml
sed -i '/TERMINAL_BLOCK_HASH_ACTIVATION_EPOCH/d' /data/testnet_setup/config.yaml
echo Using config.yaml
cat /data/testnet_setup/config.yaml
echo ""

echo "${HIVE_ETH2_CONFIG_DEPOSIT_CONTRACT_ADDRESS:-0x1111111111111111111111111111111111111111}" > /data/testnet_setup/deposit_contract.txt
echo "${HIVE_ETH2_DEPOSIT_DEPLOY_BLOCK_NUMBER:-0}" > /data/testnet_setup/deploy_block.txt
echo "${HIVE_ETH2_DEPOSIT_DEPLOY_BLOCK_NUMBER:-0}" > /data/testnet_setup/deposit_contract_block.txt
echo "${HIVE_ETH2_DEPOSIT_DEPLOY_BLOCK_HASH:-0}" > /data/testnet_setup/deposit_contract_block_hash.txt

mkdir -p /data/beacon
chmod 0700 /data/beacon
Expand Down
6 changes: 6 additions & 0 deletions clients/nimbus-bn/nimbus_version.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash

# Immediately abort the script on any error encountered
set -e

/usr/bin/nimbus_beacon_node --version | grep -Po ".*\bv?\d+\.\S+" | sed "s/ /_/g" | tr '\n' '/'
11 changes: 7 additions & 4 deletions clients/nimbus-vc/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ ENV NPROC=2

RUN git clone --depth 1 --branch unstable https://github.com/status-im/nimbus-eth2.git \
&& cd nimbus-eth2 \
&& make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC} -d:SECONDS_PER_SLOT=6" V=1 update
&& make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC}" V=1 update

RUN cd nimbus-eth2 && \
make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC} -d:SECONDS_PER_SLOT=6" nimbus_validator_client && \
make -j${NPROC} NIMFLAGS="--parallelBuild:${NPROC}" nimbus_validator_client && \
mv build/nimbus_validator_client /usr/bin/

# --------------------------------- #
Expand All @@ -30,10 +30,13 @@ RUN apt-get update \

COPY --from=build /usr/bin/nimbus_validator_client /usr/bin/nimbus_validator_client

RUN usr/bin/nimbus_validator_client --version > /version.txt

# Add the startup script.
ADD nimbus_vc.sh /nimbus_vc.sh
RUN chmod +x /nimbus_vc.sh

ADD nimbus_version.sh /nimbus_version.sh
RUN chmod +x /nimbus_version.sh

RUN /nimbus_version.sh > /version.txt

ENTRYPOINT ["/nimbus_vc.sh"]
6 changes: 6 additions & 0 deletions clients/nimbus-vc/nimbus_version.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash

# Immediately abort the script on any error encountered
set -e

/usr/bin/nimbus_validator_client --version | grep -Po ".*\bv?\d+\.\S+" | sed "s/ /_/g" | tr '\n' '/'
26 changes: 26 additions & 0 deletions clients/reth/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
ARG branch=main
FROM paradigmxyz/reth:$branch

# Install script tools.
RUN apt-get update -y
RUN apt-get install -y bash curl jq

# Add genesis mapper script.
ADD genesis.json /genesis.json
ADD mapper.jq /mapper.jq

# Add the startup script.
ADD reth.sh /reth.sh
RUN chmod +x /reth.sh

# Add the enode URL retriever script.
ADD enode.sh /hive-bin/enode.sh
RUN chmod +x /hive-bin/enode.sh

# Create version.txt
RUN /usr/local/bin/reth --version | sed -e 's/reth \(.*\)/\1/' > /version.txt

# Export the usual networking ports to allow outside access to the node.
EXPOSE 8545 8546 30303 30303/udp

ENTRYPOINT ["/reth.sh"]