Compare commits
9 Commits
98e1c88293
...
vibe
| Author | SHA1 | Date | |
|---|---|---|---|
| 5f85d6b5a4 | |||
| ec2fb6c883 | |||
| d28342683c | |||
| 52d7ec6d40 | |||
| 6917005776 | |||
| 63b720f1e9 | |||
| db681b5a74 | |||
| 42a91a5bac | |||
| 8dfdaf3548 |
@@ -23,18 +23,33 @@ for path in $pathlist; do
|
||||
RPC_URL="https://$DOMAIN/$path"
|
||||
response_file=$(mktemp)
|
||||
|
||||
http_status_code=$(curl --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}' $RPC_URL)
|
||||
# Detect Starknet vs Ethereum based on path
|
||||
if echo "$path" | grep -qi "starknet"; then
|
||||
rpc_method='{"jsonrpc":"2.0","method":"starknet_getBlockWithTxHashes","params":["latest"],"id":1}'
|
||||
is_starknet=true
|
||||
else
|
||||
rpc_method='{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}'
|
||||
is_starknet=false
|
||||
fi
|
||||
|
||||
http_status_code=$(curl --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data "$rpc_method" $RPC_URL)
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
|
||||
|
||||
if [[ $http_status_code -eq 200 ]]; then
|
||||
response=$(cat "$response_file")
|
||||
|
||||
latest_block_number=$(echo "$response" | jq -r '.result.number')
|
||||
latest_block_number_decimal=$((16#${latest_block_number#0x}))
|
||||
if $is_starknet; then
|
||||
# Starknet returns decimal block_number
|
||||
latest_block_number_decimal=$(echo "$response" | jq -r '.result.block_number')
|
||||
else
|
||||
# Ethereum returns hex number
|
||||
latest_block_number=$(echo "$response" | jq -r '.result.number')
|
||||
latest_block_number_decimal=$((16#${latest_block_number#0x}))
|
||||
fi
|
||||
|
||||
echo "$latest_block_number_decimal"
|
||||
|
||||
|
||||
exit 0;
|
||||
fi
|
||||
fi
|
||||
|
||||
@@ -8,9 +8,17 @@ if [ $# -lt 2 ]; then
|
||||
fi
|
||||
|
||||
RPC_URL=$1
|
||||
REF=""
|
||||
shift
|
||||
|
||||
for url in "${@:2}"; do
|
||||
# Check for --starknet flag
|
||||
is_starknet=false
|
||||
if [ "$1" == "--starknet" ]; then
|
||||
is_starknet=true
|
||||
shift
|
||||
fi
|
||||
|
||||
REF=""
|
||||
for url in "$@"; do
|
||||
REF+="--url $url "
|
||||
done
|
||||
|
||||
@@ -23,49 +31,84 @@ timeout=3 # seconds
|
||||
|
||||
response_file=$(mktemp)
|
||||
|
||||
http_status_code=$(curl -L --ipv4 -m $timeout -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}' $RPC_URL)
|
||||
# Use appropriate RPC method based on chain type
|
||||
if $is_starknet; then
|
||||
rpc_method='{"jsonrpc":"2.0","method":"starknet_getBlockWithTxHashes","params":["latest"],"id":1}'
|
||||
else
|
||||
rpc_method='{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}'
|
||||
fi
|
||||
|
||||
http_status_code=$(curl -L --ipv4 -m $timeout -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data "$rpc_method" $RPC_URL)
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
if [[ $http_status_code -eq 200 ]]; then
|
||||
response=$(cat "$response_file")
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal=$((16#${latest_block_timestamp#0x}))
|
||||
|
||||
if $is_starknet; then
|
||||
# Starknet returns decimal timestamp and block_number
|
||||
latest_block_timestamp_decimal=$(echo "$response" | jq -r '.result.timestamp')
|
||||
latest_block_number=$(echo "$response" | jq -r '.result.block_number')
|
||||
latest_block_hash=$(echo "$response" | jq -r '.result.block_hash')
|
||||
else
|
||||
# Ethereum returns hex timestamp and number
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal=$((16#${latest_block_timestamp#0x}))
|
||||
latest_block_number=$(echo "$response" | jq -r '.result.number')
|
||||
latest_block_hash=$(echo "$response" | jq -r '.result.hash')
|
||||
fi
|
||||
|
||||
current_time=$(date +%s)
|
||||
time_difference=$((current_time - latest_block_timestamp_decimal))
|
||||
|
||||
rm "$response_file"
|
||||
|
||||
if [ -n "$ref" ]; then
|
||||
latest_block_number=$(echo "$response" | jq -r '.result.number')
|
||||
latest_block_hash=$(echo "$response" | jq -r '.result.hash')
|
||||
|
||||
if [ -n "$ref" ]; then
|
||||
response_file2=$(mktemp)
|
||||
|
||||
sleep 3 # to give the reference node more time to import the block if it is very current
|
||||
|
||||
http_status_code2=$($BASEPATH/multicurl.sh -L --ipv4 -m $timeout -s -X POST -w "%{http_code}" -o "$response_file2" -H "Content-Type: application/json" --data "{\"jsonrpc\":\"2.0\",\"method\":\"eth_getBlockByNumber\",\"params\":[\"$latest_block_number\", false],\"id\":1}" $ref)
|
||||
|
||||
if $is_starknet; then
|
||||
# Starknet uses block_id object with block_number
|
||||
rpc_method2="{\"jsonrpc\":\"2.0\",\"method\":\"starknet_getBlockWithTxHashes\",\"params\":[{\"block_number\":$latest_block_number}],\"id\":1}"
|
||||
else
|
||||
rpc_method2="{\"jsonrpc\":\"2.0\",\"method\":\"eth_getBlockByNumber\",\"params\":[\"$latest_block_number\", false],\"id\":1}"
|
||||
fi
|
||||
|
||||
http_status_code2=$($BASEPATH/multicurl.sh -L --ipv4 -m $timeout -s -X POST -w "%{http_code}" -o "$response_file2" -H "Content-Type: application/json" --data "$rpc_method2" $ref)
|
||||
|
||||
curl_code2=$?
|
||||
|
||||
if [ $curl_code2 -eq 0 ]; then
|
||||
|
||||
if [ $curl_code2 -eq 0 ]; then
|
||||
if [[ $http_status_code2 -eq 200 ]]; then
|
||||
response2=$(cat "$response_file2")
|
||||
latest_block_hash2=$(echo "$response2" | jq -r '.result.hash')
|
||||
if $is_starknet; then
|
||||
latest_block_hash2=$(echo "$response2" | jq -r '.result.block_hash')
|
||||
else
|
||||
latest_block_hash2=$(echo "$response2" | jq -r '.result.hash')
|
||||
fi
|
||||
|
||||
rm "$response_file2"
|
||||
|
||||
if [ "$latest_block_hash" == "$latest_block_hash2" ]; then
|
||||
response_file3=$(mktemp)
|
||||
status_file3=$(mktemp)
|
||||
|
||||
if $is_starknet; then
|
||||
rpc_method_latest='{"jsonrpc":"2.0","method":"starknet_getBlockWithTxHashes","params":["latest"],"id":1}'
|
||||
else
|
||||
rpc_method_latest='{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}'
|
||||
fi
|
||||
|
||||
{
|
||||
$BASEPATH/multicurl.sh -L --ipv4 -m $timeout -s -X POST -w "%{http_code} %{time_total}" -o "$response_file3" -H "Content-Type: application/json" --data "{\"jsonrpc\":\"2.0\",\"method\":\"eth_getBlockByNumber\",\"params\":[\"latest\", false],\"id\":1}" $ref > "$status_file3"
|
||||
} &
|
||||
$BASEPATH/multicurl.sh -L --ipv4 -m $timeout -s -X POST -w "%{http_code} %{time_total}" -o "$response_file3" -H "Content-Type: application/json" --data "$rpc_method_latest" $ref > "$status_file3"
|
||||
} &
|
||||
pid3=$!
|
||||
|
||||
response_file4=$(mktemp)
|
||||
status_file4=$(mktemp)
|
||||
|
||||
{
|
||||
curl -L --ipv4 -m $timeout -s -X POST -w "%{http_code} %{time_total}" -o "$response_file4" -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}' $RPC_URL > "$status_file4"
|
||||
curl -L --ipv4 -m $timeout -s -X POST -w "%{http_code} %{time_total}" -o "$response_file4" -H "Content-Type: application/json" --data "$rpc_method_latest" $RPC_URL > "$status_file4"
|
||||
} &
|
||||
pid4=$!
|
||||
|
||||
@@ -86,17 +129,27 @@ if [ $? -eq 0 ]; then
|
||||
if [ $curl_code3 -eq 0 ]; then
|
||||
if [[ $http_status_code3 -eq 200 ]]; then
|
||||
response3=$(cat "$response_file3")
|
||||
latest_block_timestamp3=$(echo "$response3" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal3=$((16#${latest_block_timestamp3#0x}))
|
||||
|
||||
# echo "refer: $latest_block_timestamp_decimal3"
|
||||
if $is_starknet; then
|
||||
latest_block_timestamp_decimal3=$(echo "$response3" | jq -r '.result.timestamp')
|
||||
else
|
||||
latest_block_timestamp3=$(echo "$response3" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal3=$((16#${latest_block_timestamp3#0x}))
|
||||
fi
|
||||
|
||||
# echo "refer: $latest_block_timestamp_decimal3"
|
||||
rm "$response_file3"
|
||||
|
||||
if [ $curl_code4 -eq 0 ]; then
|
||||
if [[ $http_status_code4 -eq 200 ]]; then
|
||||
response4=$(cat "$response_file4")
|
||||
latest_block_timestamp4=$(echo "$response4" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal4=$((16#${latest_block_timestamp4#0x}))
|
||||
|
||||
if $is_starknet; then
|
||||
latest_block_timestamp_decimal4=$(echo "$response4" | jq -r '.result.timestamp')
|
||||
else
|
||||
latest_block_timestamp4=$(echo "$response4" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal4=$((16#${latest_block_timestamp4#0x}))
|
||||
fi
|
||||
|
||||
#echo "local: $latest_block_timestamp_decimal4"
|
||||
rm "$response_file4"
|
||||
|
||||
@@ -3162,6 +3162,78 @@
|
||||
"linea-sepolia-erigon3-pruned-trace_maru"
|
||||
]
|
||||
},
|
||||
{
|
||||
"chain": "mainnet",
|
||||
"client": "geth",
|
||||
"compose_file": "linea/geth/linea-mainnet-geth-archive-leveldb-hash",
|
||||
"features": [
|
||||
"hash",
|
||||
"leveldb"
|
||||
],
|
||||
"network": "linea",
|
||||
"node": "maru",
|
||||
"relay": null,
|
||||
"stack": null,
|
||||
"type": "archive",
|
||||
"volumes": [
|
||||
"linea-mainnet-geth-archive-leveldb-hash",
|
||||
"linea-mainnet-geth-archive-leveldb-hash_maru"
|
||||
]
|
||||
},
|
||||
{
|
||||
"chain": "mainnet",
|
||||
"client": "geth",
|
||||
"compose_file": "linea/geth/linea-mainnet-geth-pruned-pebble-path",
|
||||
"features": [
|
||||
"path",
|
||||
"pebble"
|
||||
],
|
||||
"network": "linea",
|
||||
"node": "maru",
|
||||
"relay": null,
|
||||
"stack": null,
|
||||
"type": "pruned",
|
||||
"volumes": [
|
||||
"linea-mainnet-geth-pruned-pebble-path",
|
||||
"linea-mainnet-geth-pruned-pebble-path_maru"
|
||||
]
|
||||
},
|
||||
{
|
||||
"chain": "sepolia",
|
||||
"client": "geth",
|
||||
"compose_file": "linea/geth/linea-sepolia-geth-archive-leveldb-hash",
|
||||
"features": [
|
||||
"hash",
|
||||
"leveldb"
|
||||
],
|
||||
"network": "linea",
|
||||
"node": "maru",
|
||||
"relay": null,
|
||||
"stack": null,
|
||||
"type": "archive",
|
||||
"volumes": [
|
||||
"linea-sepolia-geth-archive-leveldb-hash",
|
||||
"linea-sepolia-geth-archive-leveldb-hash_maru"
|
||||
]
|
||||
},
|
||||
{
|
||||
"chain": "sepolia",
|
||||
"client": "geth",
|
||||
"compose_file": "linea/geth/linea-sepolia-geth-pruned-pebble-path",
|
||||
"features": [
|
||||
"path",
|
||||
"pebble"
|
||||
],
|
||||
"network": "linea",
|
||||
"node": "maru",
|
||||
"relay": null,
|
||||
"stack": null,
|
||||
"type": "pruned",
|
||||
"volumes": [
|
||||
"linea-sepolia-geth-pruned-pebble-path",
|
||||
"linea-sepolia-geth-pruned-pebble-path_maru"
|
||||
]
|
||||
},
|
||||
{
|
||||
"chain": "mainnet",
|
||||
"client": "reth",
|
||||
|
||||
@@ -117,7 +117,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 19816:19816
|
||||
- 19816:19816/udp
|
||||
@@ -133,7 +133,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -117,7 +117,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 19691:19691
|
||||
- 19691:19691/udp
|
||||
@@ -133,7 +133,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -113,7 +113,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 15060:15060
|
||||
- 15060:15060/udp
|
||||
@@ -129,7 +129,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -114,7 +114,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 19000:19000
|
||||
- 19000:19000/udp
|
||||
@@ -130,7 +130,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -114,7 +114,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 17622:17622
|
||||
- 17622:17622/udp
|
||||
@@ -130,7 +130,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -113,7 +113,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 17235:17235
|
||||
- 17235:17235/udp
|
||||
@@ -129,7 +129,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -114,7 +114,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 17410:17410
|
||||
- 17410:17410/udp
|
||||
@@ -130,7 +130,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
@@ -114,7 +114,7 @@ services:
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-9737a45}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 15620:15620
|
||||
- 15620:15620/udp
|
||||
@@ -130,7 +130,7 @@ services:
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --config=/config.toml --maru-genesis-file=/config/maru/genesis.json "$@"
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
|
||||
186
linea/geth/linea-mainnet-geth-archive-leveldb-hash.yml
Normal file
186
linea/geth/linea-mainnet-geth-archive-leveldb-hash.yml
Normal file
@@ -0,0 +1,186 @@
|
||||
---
|
||||
x-logging-defaults: &logging-defaults
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# mkdir rpc && cd rpc
|
||||
#
|
||||
# git init
|
||||
# git remote add origin https://github.com/StakeSquid/ethereum-rpc-docker.git
|
||||
# git fetch origin vibe
|
||||
# git checkout origin/vibe
|
||||
#
|
||||
# docker run --rm alpine sh -c "printf '0x'; head -c32 /dev/urandom | xxd -p -c 64" > .jwtsecret
|
||||
#
|
||||
# env
|
||||
# ...
|
||||
# IP=$(curl ipinfo.io/ip)
|
||||
# DOMAIN=${IP}.traefik.me
|
||||
# COMPOSE_FILE=base.yml:rpc.yml:linea/geth/linea-mainnet-geth-archive-leveldb-hash.yml
|
||||
#
|
||||
# docker compose up -d
|
||||
#
|
||||
# curl -X POST https://${IP}.traefik.me/linea-mainnet-geth-archive \
|
||||
# -H "Content-Type: application/json" \
|
||||
# --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'
|
||||
|
||||
services:
|
||||
linea-mainnet-geth-archive:
|
||||
image: ${LINEA_GETH_IMAGE:-ethereum/client-go}:${LINEA_MAINNET_GETH_VERSION:-v1.16.7}
|
||||
sysctls:
|
||||
# TCP Performance
|
||||
net.ipv4.tcp_slow_start_after_idle: 0 # Disable slow start after idle
|
||||
net.ipv4.tcp_no_metrics_save: 1 # Disable metrics cache
|
||||
net.ipv4.tcp_rmem: 4096 87380 16777216 # Increase TCP read buffers
|
||||
net.ipv4.tcp_wmem: 4096 87380 16777216 # Increase TCP write buffers
|
||||
net.core.somaxconn: 32768 # Higher connection queue
|
||||
# Memory/Connection Management
|
||||
# net.core.netdev_max_backlog: 50000 # Increase network buffer
|
||||
net.ipv4.tcp_max_syn_backlog: 30000 # More SYN requests
|
||||
net.ipv4.tcp_max_tw_buckets: 2000000 # Allow more TIME_WAIT sockets
|
||||
ulimits:
|
||||
nofile: 1048576 # Max open files (for RPC/WS connections)
|
||||
user: root
|
||||
ports:
|
||||
- 10037:10037
|
||||
- 10037:10037/udp
|
||||
expose:
|
||||
- 8545
|
||||
- 6060
|
||||
- 8551
|
||||
environment:
|
||||
- GETH_BOOTNODES=enode://069800db9e6e0ec9cadca670994ef1aea2cfd3d88133e63ecadbc1cdbd1a5847b09838ee08d8b5f02a9c32ee13abeb4d4104bb5514e5322c9d7ee19f41ff3e51@3.132.73.210:31002,enode://a8e03a71eab12ec4b47bb6e19169d8e4dc7a58373a2476969bbe463f2dded6003037fa4dd5f71e15027f7fc8d7340956fbbefed67ddd116ac19a7f74da034b61@3.132.73.210:31003,enode://97706526cf79df9d930003644f9156805f6c8bd964fc79e083444f7014ce10c9bdd2c5049e63b58040dca1d4c82ebef970822198cf0714de830cff4111534ff1@18.223.198.165:31004,enode://24e1c654a801975a96b7f54ebd7452ab15777fc635c1db25bdbd4425fdb04e7f4768e9e838a87ab724320a765e41631d5d37758c933ad0e8668693558125c8aa@18.223.198.165:31000,enode://27010891d960f73d272a553f72b6336c6698db3ade98d631f09c764e57674a797be5ebc6829ddbb65ab564f439ebc75215d20aa98b6f351d12ea623e7d139ac3@3.132.73.210:31001,enode://228e1b8a4931e46f383e30721dac21fb8fb4e5e1b32c870e13b25478c82db3dc1cd9e7ceb93d302a766466b55638cc9c5cbfc43aa48fa41ced19baf365951f76@3.1.142.64:31002,enode://c22eb0d40fc3ad5ea710aeddea906567778166bfe18c157955e8c39b23a46c45db18a0fa2ba07f2b64c81178a8c796aec2a29151533920ead06fcdfc6d8d03c6@47.128.192.57:31004,enode://8ce733abe39fd7ae0a278b9893f85c1193c611a3886168690dd843435460f22cc4d61f9e8d0ace7f5905836a665319a31cccdaacdada2acc69972c382ecce7db@3.1.142.64:31003,enode://b7c1b2bed65a855f7a2104aac9a14674dfdf018fdac763415b373b29ce18cdb81d36328ba4e5c9f12629f3a50c3e8f9ee048f22dbdbe93a82813da89c6b81334@51.20.235.126:31004,enode://95270e0550848a72fb141cf27f1c4ea10714edde365b411dc0fa06c81c0f282ce155eb9fa472b6b8bb9ee98395eeaf4c5a7b02a01fe58b37ea98ba152eda4c37@13.50.94.193:31000,enode://72013391755f24f08567b932feeeec4c893c06e0b1fb480890c83bf87fd277ad86a5ab9cb586db9ae9970371a2f8cb0c96f6c9f69045abca0fb801db7f047138@51.20.235.126:31001
|
||||
entrypoint: /bin/sh -c '[ ! -d /root/.ethereum/geth ] && geth --db.engine=leveldb --gcmode=archive --datadir /root/.ethereum init --state.scheme=hash /config/genesis.json; exec geth "$@"' --
|
||||
command:
|
||||
- --bootnodes=enode://069800db9e6e0ec9cadca670994ef1aea2cfd3d88133e63ecadbc1cdbd1a5847b09838ee08d8b5f02a9c32ee13abeb4d4104bb5514e5322c9d7ee19f41ff3e51@3.132.73.210:31002,enode://a8e03a71eab12ec4b47bb6e19169d8e4dc7a58373a2476969bbe463f2dded6003037fa4dd5f71e15027f7fc8d7340956fbbefed67ddd116ac19a7f74da034b61@3.132.73.210:31003,enode://97706526cf79df9d930003644f9156805f6c8bd964fc79e083444f7014ce10c9bdd2c5049e63b58040dca1d4c82ebef970822198cf0714de830cff4111534ff1@18.223.198.165:31004,enode://24e1c654a801975a96b7f54ebd7452ab15777fc635c1db25bdbd4425fdb04e7f4768e9e838a87ab724320a765e41631d5d37758c933ad0e8668693558125c8aa@18.223.198.165:31000,enode://27010891d960f73d272a553f72b6336c6698db3ade98d631f09c764e57674a797be5ebc6829ddbb65ab564f439ebc75215d20aa98b6f351d12ea623e7d139ac3@3.132.73.210:31001,enode://228e1b8a4931e46f383e30721dac21fb8fb4e5e1b32c870e13b25478c82db3dc1cd9e7ceb93d302a766466b55638cc9c5cbfc43aa48fa41ced19baf365951f76@3.1.142.64:31002,enode://c22eb0d40fc3ad5ea710aeddea906567778166bfe18c157955e8c39b23a46c45db18a0fa2ba07f2b64c81178a8c796aec2a29151533920ead06fcdfc6d8d03c6@47.128.192.57:31004,enode://8ce733abe39fd7ae0a278b9893f85c1193c611a3886168690dd843435460f22cc4d61f9e8d0ace7f5905836a665319a31cccdaacdada2acc69972c382ecce7db@3.1.142.64:31003,enode://b7c1b2bed65a855f7a2104aac9a14674dfdf018fdac763415b373b29ce18cdb81d36328ba4e5c9f12629f3a50c3e8f9ee048f22dbdbe93a82813da89c6b81334@51.20.235.126:31004,enode://95270e0550848a72fb141cf27f1c4ea10714edde365b411dc0fa06c81c0f282ce155eb9fa472b6b8bb9ee98395eeaf4c5a7b02a01fe58b37ea98ba152eda4c37@13.50.94.193:31000,enode://72013391755f24f08567b932feeeec4c893c06e0b1fb480890c83bf87fd277ad86a5ab9cb586db9ae9970371a2f8cb0c96f6c9f69045abca0fb801db7f047138@51.20.235.126:31001
|
||||
- --datadir=/root/.ethereum
|
||||
- --db.engine=leveldb
|
||||
- --gcmode=archive
|
||||
- --maxpeers=50
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --nat=extip:${IP}
|
||||
- --port=10037
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
- --state.scheme=hash
|
||||
- --syncmode=full
|
||||
- --http
|
||||
- --http.addr=0.0.0.0
|
||||
- --http.api=eth,net,web3,debug,admin,txpool
|
||||
- --http.port=8545
|
||||
- --http.vhosts=*
|
||||
- --ws
|
||||
- --ws.addr=0.0.0.0
|
||||
- --ws.api=eth,net,web3,debug,admin,txpool
|
||||
- --ws.origins=*
|
||||
- --ws.port=8545
|
||||
- --authrpc.addr=0.0.0.0
|
||||
- --authrpc.jwtsecret=/jwtsecret
|
||||
- --authrpc.vhosts=*
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_MAINNET_GETH_ARCHIVE_LEVELDB_HASH_DATA:-linea-mainnet-geth-archive-leveldb-hash}:/root/.ethereum
|
||||
- ./linea/mainnet:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
- /slowdisk:/slowdisk
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=6060
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
- traefik.enable=true
|
||||
- traefik.http.middlewares.linea-mainnet-geth-archive-leveldb-hash-stripprefix.stripprefix.prefixes=/linea-mainnet-geth-archive
|
||||
- traefik.http.services.linea-mainnet-geth-archive-leveldb-hash.loadbalancer.server.port=8545
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-archive-leveldb-hash.entrypoints=websecure}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-archive-leveldb-hash.tls.certresolver=myresolver}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-archive-leveldb-hash.rule=Host(`$DOMAIN`) && (Path(`/linea-mainnet-geth-archive`) || Path(`/linea-mainnet-geth-archive/`))}
|
||||
- ${NO_SSL:+traefik.http.routers.linea-mainnet-geth-archive-leveldb-hash.rule=Path(`/linea-mainnet-geth-archive`) || Path(`/linea-mainnet-geth-archive/`)}
|
||||
- traefik.http.routers.linea-mainnet-geth-archive-leveldb-hash.middlewares=linea-mainnet-geth-archive-leveldb-hash-stripprefix, ipallowlist
|
||||
|
||||
linea-mainnet-geth-archive-node:
|
||||
build:
|
||||
context: ./linea
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 15037:15037
|
||||
- 15037:15037/udp
|
||||
expose:
|
||||
- 8080
|
||||
environment:
|
||||
- EL_HOST=linea-mainnet-geth-archive
|
||||
- IP=${IP}
|
||||
- L1_RPC=${ETHEREUM_MAINNET_EXECUTION_RPC}
|
||||
- P2P_PORT=15037
|
||||
- SEQUENCER=https://rpc.linea.build
|
||||
entrypoint: [/bin/bash, -c]
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_MAINNET_GETH_ARCHIVE_LEVELDB_HASH__MARU_DATA:-linea-mainnet-geth-archive-leveldb-hash_maru}:/opt/maru/data
|
||||
- ./linea/mainnet:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=9090
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
|
||||
volumes:
|
||||
linea-mainnet-geth-archive-leveldb-hash:
|
||||
linea-mainnet-geth-archive-leveldb-hash_maru:
|
||||
|
||||
x-upstreams:
|
||||
- id: $${ID}
|
||||
labels:
|
||||
provider: $${PROVIDER}
|
||||
connection:
|
||||
generic:
|
||||
rpc:
|
||||
url: $${RPC_URL}
|
||||
ws:
|
||||
frameSize: 20Mb
|
||||
msgSize: 50Mb
|
||||
url: $${WS_URL}
|
||||
chain: linea
|
||||
method-groups:
|
||||
enabled:
|
||||
- debug
|
||||
- filter
|
||||
methods:
|
||||
disabled:
|
||||
enabled:
|
||||
- name: txpool_content # TODO: should be disabled for rollup nodes
|
||||
# standard geth only
|
||||
- name: debug_getRawBlock
|
||||
- name: debug_getRawTransaction
|
||||
- name: debug_getRawReceipts
|
||||
- name: debug_getRawHeader
|
||||
- name: debug_getBadBlocks
|
||||
# non standard geth only slightly dangerous
|
||||
- name: debug_intermediateRoots
|
||||
- name: debug_dumpBlock
|
||||
# standard geth and erigon
|
||||
- name: debug_accountRange
|
||||
- name: debug_getModifiedAccountsByNumber
|
||||
- name: debug_getModifiedAccountsByHash
|
||||
# non standard geth and erigon
|
||||
- name: eth_getRawTransactionByHash
|
||||
- name: eth_getRawTransactionByBlockHashAndIndex
|
||||
...
|
||||
188
linea/geth/linea-mainnet-geth-pruned-pebble-path.yml
Normal file
188
linea/geth/linea-mainnet-geth-pruned-pebble-path.yml
Normal file
@@ -0,0 +1,188 @@
|
||||
---
|
||||
x-logging-defaults: &logging-defaults
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# mkdir rpc && cd rpc
|
||||
#
|
||||
# git init
|
||||
# git remote add origin https://github.com/StakeSquid/ethereum-rpc-docker.git
|
||||
# git fetch origin vibe
|
||||
# git checkout origin/vibe
|
||||
#
|
||||
# docker run --rm alpine sh -c "printf '0x'; head -c32 /dev/urandom | xxd -p -c 64" > .jwtsecret
|
||||
#
|
||||
# env
|
||||
# ...
|
||||
# IP=$(curl ipinfo.io/ip)
|
||||
# DOMAIN=${IP}.traefik.me
|
||||
# COMPOSE_FILE=base.yml:rpc.yml:linea/geth/linea-mainnet-geth-pruned-pebble-path.yml
|
||||
#
|
||||
# docker compose up -d
|
||||
#
|
||||
# curl -X POST https://${IP}.traefik.me/linea-mainnet-geth \
|
||||
# -H "Content-Type: application/json" \
|
||||
# --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'
|
||||
|
||||
services:
|
||||
linea-mainnet-geth:
|
||||
image: ${LINEA_GETH_IMAGE:-ethereum/client-go}:${LINEA_MAINNET_GETH_VERSION:-v1.16.7}
|
||||
sysctls:
|
||||
# TCP Performance
|
||||
net.ipv4.tcp_slow_start_after_idle: 0 # Disable slow start after idle
|
||||
net.ipv4.tcp_no_metrics_save: 1 # Disable metrics cache
|
||||
net.ipv4.tcp_rmem: 4096 87380 16777216 # Increase TCP read buffers
|
||||
net.ipv4.tcp_wmem: 4096 87380 16777216 # Increase TCP write buffers
|
||||
net.core.somaxconn: 32768 # Higher connection queue
|
||||
# Memory/Connection Management
|
||||
# net.core.netdev_max_backlog: 50000 # Increase network buffer
|
||||
net.ipv4.tcp_max_syn_backlog: 30000 # More SYN requests
|
||||
net.ipv4.tcp_max_tw_buckets: 2000000 # Allow more TIME_WAIT sockets
|
||||
ulimits:
|
||||
nofile: 1048576 # Max open files (for RPC/WS connections)
|
||||
user: root
|
||||
ports:
|
||||
- 13522:13522
|
||||
- 13522:13522/udp
|
||||
expose:
|
||||
- 8545
|
||||
- 6060
|
||||
- 8551
|
||||
environment:
|
||||
- GETH_BOOTNODES=enode://069800db9e6e0ec9cadca670994ef1aea2cfd3d88133e63ecadbc1cdbd1a5847b09838ee08d8b5f02a9c32ee13abeb4d4104bb5514e5322c9d7ee19f41ff3e51@3.132.73.210:31002,enode://a8e03a71eab12ec4b47bb6e19169d8e4dc7a58373a2476969bbe463f2dded6003037fa4dd5f71e15027f7fc8d7340956fbbefed67ddd116ac19a7f74da034b61@3.132.73.210:31003,enode://97706526cf79df9d930003644f9156805f6c8bd964fc79e083444f7014ce10c9bdd2c5049e63b58040dca1d4c82ebef970822198cf0714de830cff4111534ff1@18.223.198.165:31004,enode://24e1c654a801975a96b7f54ebd7452ab15777fc635c1db25bdbd4425fdb04e7f4768e9e838a87ab724320a765e41631d5d37758c933ad0e8668693558125c8aa@18.223.198.165:31000,enode://27010891d960f73d272a553f72b6336c6698db3ade98d631f09c764e57674a797be5ebc6829ddbb65ab564f439ebc75215d20aa98b6f351d12ea623e7d139ac3@3.132.73.210:31001,enode://228e1b8a4931e46f383e30721dac21fb8fb4e5e1b32c870e13b25478c82db3dc1cd9e7ceb93d302a766466b55638cc9c5cbfc43aa48fa41ced19baf365951f76@3.1.142.64:31002,enode://c22eb0d40fc3ad5ea710aeddea906567778166bfe18c157955e8c39b23a46c45db18a0fa2ba07f2b64c81178a8c796aec2a29151533920ead06fcdfc6d8d03c6@47.128.192.57:31004,enode://8ce733abe39fd7ae0a278b9893f85c1193c611a3886168690dd843435460f22cc4d61f9e8d0ace7f5905836a665319a31cccdaacdada2acc69972c382ecce7db@3.1.142.64:31003,enode://b7c1b2bed65a855f7a2104aac9a14674dfdf018fdac763415b373b29ce18cdb81d36328ba4e5c9f12629f3a50c3e8f9ee048f22dbdbe93a82813da89c6b81334@51.20.235.126:31004,enode://95270e0550848a72fb141cf27f1c4ea10714edde365b411dc0fa06c81c0f282ce155eb9fa472b6b8bb9ee98395eeaf4c5a7b02a01fe58b37ea98ba152eda4c37@13.50.94.193:31000,enode://72013391755f24f08567b932feeeec4c893c06e0b1fb480890c83bf87fd277ad86a5ab9cb586db9ae9970371a2f8cb0c96f6c9f69045abca0fb801db7f047138@51.20.235.126:31001
|
||||
entrypoint: /bin/sh -c '[ ! -d /root/.ethereum/geth ] && geth --db.engine=pebble --gcmode=full --datadir /root/.ethereum init --state.scheme=path /config/genesis.json; exec geth "$@"' --
|
||||
command:
|
||||
- --bootnodes=enode://069800db9e6e0ec9cadca670994ef1aea2cfd3d88133e63ecadbc1cdbd1a5847b09838ee08d8b5f02a9c32ee13abeb4d4104bb5514e5322c9d7ee19f41ff3e51@3.132.73.210:31002,enode://a8e03a71eab12ec4b47bb6e19169d8e4dc7a58373a2476969bbe463f2dded6003037fa4dd5f71e15027f7fc8d7340956fbbefed67ddd116ac19a7f74da034b61@3.132.73.210:31003,enode://97706526cf79df9d930003644f9156805f6c8bd964fc79e083444f7014ce10c9bdd2c5049e63b58040dca1d4c82ebef970822198cf0714de830cff4111534ff1@18.223.198.165:31004,enode://24e1c654a801975a96b7f54ebd7452ab15777fc635c1db25bdbd4425fdb04e7f4768e9e838a87ab724320a765e41631d5d37758c933ad0e8668693558125c8aa@18.223.198.165:31000,enode://27010891d960f73d272a553f72b6336c6698db3ade98d631f09c764e57674a797be5ebc6829ddbb65ab564f439ebc75215d20aa98b6f351d12ea623e7d139ac3@3.132.73.210:31001,enode://228e1b8a4931e46f383e30721dac21fb8fb4e5e1b32c870e13b25478c82db3dc1cd9e7ceb93d302a766466b55638cc9c5cbfc43aa48fa41ced19baf365951f76@3.1.142.64:31002,enode://c22eb0d40fc3ad5ea710aeddea906567778166bfe18c157955e8c39b23a46c45db18a0fa2ba07f2b64c81178a8c796aec2a29151533920ead06fcdfc6d8d03c6@47.128.192.57:31004,enode://8ce733abe39fd7ae0a278b9893f85c1193c611a3886168690dd843435460f22cc4d61f9e8d0ace7f5905836a665319a31cccdaacdada2acc69972c382ecce7db@3.1.142.64:31003,enode://b7c1b2bed65a855f7a2104aac9a14674dfdf018fdac763415b373b29ce18cdb81d36328ba4e5c9f12629f3a50c3e8f9ee048f22dbdbe93a82813da89c6b81334@51.20.235.126:31004,enode://95270e0550848a72fb141cf27f1c4ea10714edde365b411dc0fa06c81c0f282ce155eb9fa472b6b8bb9ee98395eeaf4c5a7b02a01fe58b37ea98ba152eda4c37@13.50.94.193:31000,enode://72013391755f24f08567b932feeeec4c893c06e0b1fb480890c83bf87fd277ad86a5ab9cb586db9ae9970371a2f8cb0c96f6c9f69045abca0fb801db7f047138@51.20.235.126:31001
|
||||
- --datadir=/root/.ethereum
|
||||
- --db.engine=pebble
|
||||
- --gcmode=full
|
||||
- --maxpeers=50
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --nat=extip:${IP}
|
||||
- --port=13522
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
- --state.scheme=path
|
||||
- --syncmode=snap
|
||||
- --http
|
||||
- --http.addr=0.0.0.0
|
||||
- --http.api=eth,net,web3,debug,admin,txpool
|
||||
- --http.port=8545
|
||||
- --http.vhosts=*
|
||||
- --ws
|
||||
- --ws.addr=0.0.0.0
|
||||
- --ws.api=eth,net,web3,debug,admin,txpool
|
||||
- --ws.origins=*
|
||||
- --ws.port=8545
|
||||
- --authrpc.addr=0.0.0.0
|
||||
- --authrpc.jwtsecret=/jwtsecret
|
||||
- --authrpc.vhosts=*
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_MAINNET_GETH_PRUNED_PEBBLE_PATH_DATA:-linea-mainnet-geth-pruned-pebble-path}:/root/.ethereum
|
||||
- ./linea/mainnet:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
- /slowdisk:/slowdisk
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=6060
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
- traefik.enable=true
|
||||
- traefik.http.middlewares.linea-mainnet-geth-pruned-pebble-path-stripprefix.stripprefix.prefixes=/linea-mainnet-geth
|
||||
- traefik.http.services.linea-mainnet-geth-pruned-pebble-path.loadbalancer.server.port=8545
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-pruned-pebble-path.entrypoints=websecure}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-pruned-pebble-path.tls.certresolver=myresolver}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-mainnet-geth-pruned-pebble-path.rule=Host(`$DOMAIN`) && (Path(`/linea-mainnet-geth`) || Path(`/linea-mainnet-geth/`))}
|
||||
- ${NO_SSL:+traefik.http.routers.linea-mainnet-geth-pruned-pebble-path.rule=Path(`/linea-mainnet-geth`) || Path(`/linea-mainnet-geth/`)}
|
||||
- traefik.http.routers.linea-mainnet-geth-pruned-pebble-path.middlewares=linea-mainnet-geth-pruned-pebble-path-stripprefix, ipallowlist
|
||||
|
||||
linea-mainnet-geth-node:
|
||||
build:
|
||||
context: ./linea
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_MAINNET_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_MAINNET_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 18522:18522
|
||||
- 18522:18522/udp
|
||||
expose:
|
||||
- 8080
|
||||
environment:
|
||||
- EL_HOST=linea-mainnet-geth
|
||||
- IP=${IP}
|
||||
- L1_RPC=${ETHEREUM_MAINNET_EXECUTION_RPC}
|
||||
- P2P_PORT=18522
|
||||
- SEQUENCER=https://rpc.linea.build
|
||||
entrypoint: [/bin/bash, -c]
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-mainnet --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_MAINNET_GETH_PRUNED_PEBBLE_PATH__MARU_DATA:-linea-mainnet-geth-pruned-pebble-path_maru}:/opt/maru/data
|
||||
- ./linea/mainnet:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=9090
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
|
||||
volumes:
|
||||
linea-mainnet-geth-pruned-pebble-path:
|
||||
linea-mainnet-geth-pruned-pebble-path_maru:
|
||||
|
||||
x-upstreams:
|
||||
- id: $${ID}
|
||||
labels:
|
||||
provider: $${PROVIDER}
|
||||
connection:
|
||||
generic:
|
||||
rpc:
|
||||
url: $${RPC_URL}
|
||||
ws:
|
||||
frameSize: 20Mb
|
||||
msgSize: 50Mb
|
||||
url: $${WS_URL}
|
||||
chain: linea
|
||||
method-groups:
|
||||
enabled:
|
||||
- debug
|
||||
- filter
|
||||
methods:
|
||||
disabled:
|
||||
# not compatible with path state scheme
|
||||
- name: debug_traceBlockByHash
|
||||
enabled:
|
||||
- name: txpool_content # TODO: should be disabled for rollup nodes
|
||||
# standard geth only
|
||||
- name: debug_getRawBlock
|
||||
- name: debug_getRawTransaction
|
||||
- name: debug_getRawReceipts
|
||||
- name: debug_getRawHeader
|
||||
- name: debug_getBadBlocks
|
||||
# non standard geth only slightly dangerous
|
||||
- name: debug_intermediateRoots
|
||||
- name: debug_dumpBlock
|
||||
# standard geth and erigon
|
||||
- name: debug_accountRange
|
||||
- name: debug_getModifiedAccountsByNumber
|
||||
- name: debug_getModifiedAccountsByHash
|
||||
# non standard geth and erigon
|
||||
- name: eth_getRawTransactionByHash
|
||||
- name: eth_getRawTransactionByBlockHashAndIndex
|
||||
...
|
||||
186
linea/geth/linea-sepolia-geth-archive-leveldb-hash.yml
Normal file
186
linea/geth/linea-sepolia-geth-archive-leveldb-hash.yml
Normal file
@@ -0,0 +1,186 @@
|
||||
---
|
||||
x-logging-defaults: &logging-defaults
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# mkdir rpc && cd rpc
|
||||
#
|
||||
# git init
|
||||
# git remote add origin https://github.com/StakeSquid/ethereum-rpc-docker.git
|
||||
# git fetch origin vibe
|
||||
# git checkout origin/vibe
|
||||
#
|
||||
# docker run --rm alpine sh -c "printf '0x'; head -c32 /dev/urandom | xxd -p -c 64" > .jwtsecret
|
||||
#
|
||||
# env
|
||||
# ...
|
||||
# IP=$(curl ipinfo.io/ip)
|
||||
# DOMAIN=${IP}.traefik.me
|
||||
# COMPOSE_FILE=base.yml:rpc.yml:linea/geth/linea-sepolia-geth-archive-leveldb-hash.yml
|
||||
#
|
||||
# docker compose up -d
|
||||
#
|
||||
# curl -X POST https://${IP}.traefik.me/linea-sepolia-geth-archive \
|
||||
# -H "Content-Type: application/json" \
|
||||
# --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'
|
||||
|
||||
services:
|
||||
linea-sepolia-geth-archive:
|
||||
image: ${LINEA_GETH_IMAGE:-ethereum/client-go}:${LINEA_SEPOLIA_GETH_VERSION:-v1.16.7}
|
||||
sysctls:
|
||||
# TCP Performance
|
||||
net.ipv4.tcp_slow_start_after_idle: 0 # Disable slow start after idle
|
||||
net.ipv4.tcp_no_metrics_save: 1 # Disable metrics cache
|
||||
net.ipv4.tcp_rmem: 4096 87380 16777216 # Increase TCP read buffers
|
||||
net.ipv4.tcp_wmem: 4096 87380 16777216 # Increase TCP write buffers
|
||||
net.core.somaxconn: 32768 # Higher connection queue
|
||||
# Memory/Connection Management
|
||||
# net.core.netdev_max_backlog: 50000 # Increase network buffer
|
||||
net.ipv4.tcp_max_syn_backlog: 30000 # More SYN requests
|
||||
net.ipv4.tcp_max_tw_buckets: 2000000 # Allow more TIME_WAIT sockets
|
||||
ulimits:
|
||||
nofile: 1048576 # Max open files (for RPC/WS connections)
|
||||
user: root
|
||||
ports:
|
||||
- 11564:11564
|
||||
- 11564:11564/udp
|
||||
expose:
|
||||
- 8545
|
||||
- 6060
|
||||
- 8551
|
||||
environment:
|
||||
- GETH_BOOTNODES=enode://6f20afbe4397e51b717a7c1ad3095e79aee48c835eebd9237a3e8a16951ade1fe0e66e981e30ea269849fcb6ba03d838da37f524fabd2a557474194a2e2604fa@18.221.100.27:31002,enode://ce1e0d8e0500cb5c0ac56bdcdafb2d6320c3a2c5125b5ccf12f5dfc9b47ee74acbcafc32559017613136c9c36a0ce74ba4f83b7fb8244f099f3b15708d9d3129@3.23.75.47:31000,enode://1b026a5eb0ae74300f58987d235ef0e3a550df963345cb3574be3b0b54378bd11f14dfd515a8976f2c2d2826090e9507b8ccc24f896a9ffffffcabcfd996a733@3.129.120.128:31001
|
||||
entrypoint: /bin/sh -c '[ ! -d /root/.ethereum/geth ] && geth --db.engine=leveldb --gcmode=archive --datadir /root/.ethereum init --state.scheme=hash /config/genesis.json; exec geth "$@"' --
|
||||
command:
|
||||
- --bootnodes=enode://6f20afbe4397e51b717a7c1ad3095e79aee48c835eebd9237a3e8a16951ade1fe0e66e981e30ea269849fcb6ba03d838da37f524fabd2a557474194a2e2604fa@18.221.100.27:31002,enode://ce1e0d8e0500cb5c0ac56bdcdafb2d6320c3a2c5125b5ccf12f5dfc9b47ee74acbcafc32559017613136c9c36a0ce74ba4f83b7fb8244f099f3b15708d9d3129@3.23.75.47:31000,enode://1b026a5eb0ae74300f58987d235ef0e3a550df963345cb3574be3b0b54378bd11f14dfd515a8976f2c2d2826090e9507b8ccc24f896a9ffffffcabcfd996a733@3.129.120.128:31001
|
||||
- --datadir=/root/.ethereum
|
||||
- --db.engine=leveldb
|
||||
- --gcmode=archive
|
||||
- --maxpeers=50
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --nat=extip:${IP}
|
||||
- --port=11564
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
- --state.scheme=hash
|
||||
- --syncmode=full
|
||||
- --http
|
||||
- --http.addr=0.0.0.0
|
||||
- --http.api=eth,net,web3,debug,admin,txpool
|
||||
- --http.port=8545
|
||||
- --http.vhosts=*
|
||||
- --ws
|
||||
- --ws.addr=0.0.0.0
|
||||
- --ws.api=eth,net,web3,debug,admin,txpool
|
||||
- --ws.origins=*
|
||||
- --ws.port=8545
|
||||
- --authrpc.addr=0.0.0.0
|
||||
- --authrpc.jwtsecret=/jwtsecret
|
||||
- --authrpc.vhosts=*
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_SEPOLIA_GETH_ARCHIVE_LEVELDB_HASH_DATA:-linea-sepolia-geth-archive-leveldb-hash}:/root/.ethereum
|
||||
- ./linea/sepolia:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
- /slowdisk:/slowdisk
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=6060
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
- traefik.enable=true
|
||||
- traefik.http.middlewares.linea-sepolia-geth-archive-leveldb-hash-stripprefix.stripprefix.prefixes=/linea-sepolia-geth-archive
|
||||
- traefik.http.services.linea-sepolia-geth-archive-leveldb-hash.loadbalancer.server.port=8545
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-archive-leveldb-hash.entrypoints=websecure}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-archive-leveldb-hash.tls.certresolver=myresolver}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-archive-leveldb-hash.rule=Host(`$DOMAIN`) && (Path(`/linea-sepolia-geth-archive`) || Path(`/linea-sepolia-geth-archive/`))}
|
||||
- ${NO_SSL:+traefik.http.routers.linea-sepolia-geth-archive-leveldb-hash.rule=Path(`/linea-sepolia-geth-archive`) || Path(`/linea-sepolia-geth-archive/`)}
|
||||
- traefik.http.routers.linea-sepolia-geth-archive-leveldb-hash.middlewares=linea-sepolia-geth-archive-leveldb-hash-stripprefix, ipallowlist
|
||||
|
||||
linea-sepolia-geth-archive-node:
|
||||
build:
|
||||
context: ./linea
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 16564:16564
|
||||
- 16564:16564/udp
|
||||
expose:
|
||||
- 8080
|
||||
environment:
|
||||
- EL_HOST=linea-sepolia-geth-archive
|
||||
- IP=${IP}
|
||||
- L1_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- P2P_PORT=16564
|
||||
- SEQUENCER=https://rpc.sepolia.linea.build
|
||||
entrypoint: [/bin/bash, -c]
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_SEPOLIA_GETH_ARCHIVE_LEVELDB_HASH__MARU_DATA:-linea-sepolia-geth-archive-leveldb-hash_maru}:/opt/maru/data
|
||||
- ./linea/sepolia:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=9090
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
|
||||
volumes:
|
||||
linea-sepolia-geth-archive-leveldb-hash:
|
||||
linea-sepolia-geth-archive-leveldb-hash_maru:
|
||||
|
||||
x-upstreams:
|
||||
- id: $${ID}
|
||||
labels:
|
||||
provider: $${PROVIDER}
|
||||
connection:
|
||||
generic:
|
||||
rpc:
|
||||
url: $${RPC_URL}
|
||||
ws:
|
||||
frameSize: 20Mb
|
||||
msgSize: 50Mb
|
||||
url: $${WS_URL}
|
||||
chain: linea-sepolia
|
||||
method-groups:
|
||||
enabled:
|
||||
- debug
|
||||
- filter
|
||||
methods:
|
||||
disabled:
|
||||
enabled:
|
||||
- name: txpool_content # TODO: should be disabled for rollup nodes
|
||||
# standard geth only
|
||||
- name: debug_getRawBlock
|
||||
- name: debug_getRawTransaction
|
||||
- name: debug_getRawReceipts
|
||||
- name: debug_getRawHeader
|
||||
- name: debug_getBadBlocks
|
||||
# non standard geth only slightly dangerous
|
||||
- name: debug_intermediateRoots
|
||||
- name: debug_dumpBlock
|
||||
# standard geth and erigon
|
||||
- name: debug_accountRange
|
||||
- name: debug_getModifiedAccountsByNumber
|
||||
- name: debug_getModifiedAccountsByHash
|
||||
# non standard geth and erigon
|
||||
- name: eth_getRawTransactionByHash
|
||||
- name: eth_getRawTransactionByBlockHashAndIndex
|
||||
...
|
||||
188
linea/geth/linea-sepolia-geth-pruned-pebble-path.yml
Normal file
188
linea/geth/linea-sepolia-geth-pruned-pebble-path.yml
Normal file
@@ -0,0 +1,188 @@
|
||||
---
|
||||
x-logging-defaults: &logging-defaults
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
# Usage:
|
||||
#
|
||||
# mkdir rpc && cd rpc
|
||||
#
|
||||
# git init
|
||||
# git remote add origin https://github.com/StakeSquid/ethereum-rpc-docker.git
|
||||
# git fetch origin vibe
|
||||
# git checkout origin/vibe
|
||||
#
|
||||
# docker run --rm alpine sh -c "printf '0x'; head -c32 /dev/urandom | xxd -p -c 64" > .jwtsecret
|
||||
#
|
||||
# env
|
||||
# ...
|
||||
# IP=$(curl ipinfo.io/ip)
|
||||
# DOMAIN=${IP}.traefik.me
|
||||
# COMPOSE_FILE=base.yml:rpc.yml:linea/geth/linea-sepolia-geth-pruned-pebble-path.yml
|
||||
#
|
||||
# docker compose up -d
|
||||
#
|
||||
# curl -X POST https://${IP}.traefik.me/linea-sepolia-geth \
|
||||
# -H "Content-Type: application/json" \
|
||||
# --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'
|
||||
|
||||
services:
|
||||
linea-sepolia-geth:
|
||||
image: ${LINEA_GETH_IMAGE:-ethereum/client-go}:${LINEA_SEPOLIA_GETH_VERSION:-v1.16.7}
|
||||
sysctls:
|
||||
# TCP Performance
|
||||
net.ipv4.tcp_slow_start_after_idle: 0 # Disable slow start after idle
|
||||
net.ipv4.tcp_no_metrics_save: 1 # Disable metrics cache
|
||||
net.ipv4.tcp_rmem: 4096 87380 16777216 # Increase TCP read buffers
|
||||
net.ipv4.tcp_wmem: 4096 87380 16777216 # Increase TCP write buffers
|
||||
net.core.somaxconn: 32768 # Higher connection queue
|
||||
# Memory/Connection Management
|
||||
# net.core.netdev_max_backlog: 50000 # Increase network buffer
|
||||
net.ipv4.tcp_max_syn_backlog: 30000 # More SYN requests
|
||||
net.ipv4.tcp_max_tw_buckets: 2000000 # Allow more TIME_WAIT sockets
|
||||
ulimits:
|
||||
nofile: 1048576 # Max open files (for RPC/WS connections)
|
||||
user: root
|
||||
ports:
|
||||
- 14190:14190
|
||||
- 14190:14190/udp
|
||||
expose:
|
||||
- 8545
|
||||
- 6060
|
||||
- 8551
|
||||
environment:
|
||||
- GETH_BOOTNODES=enode://6f20afbe4397e51b717a7c1ad3095e79aee48c835eebd9237a3e8a16951ade1fe0e66e981e30ea269849fcb6ba03d838da37f524fabd2a557474194a2e2604fa@18.221.100.27:31002,enode://ce1e0d8e0500cb5c0ac56bdcdafb2d6320c3a2c5125b5ccf12f5dfc9b47ee74acbcafc32559017613136c9c36a0ce74ba4f83b7fb8244f099f3b15708d9d3129@3.23.75.47:31000,enode://1b026a5eb0ae74300f58987d235ef0e3a550df963345cb3574be3b0b54378bd11f14dfd515a8976f2c2d2826090e9507b8ccc24f896a9ffffffcabcfd996a733@3.129.120.128:31001
|
||||
entrypoint: /bin/sh -c '[ ! -d /root/.ethereum/geth ] && geth --db.engine=pebble --gcmode=full --datadir /root/.ethereum init --state.scheme=path /config/genesis.json; exec geth "$@"' --
|
||||
command:
|
||||
- --bootnodes=enode://6f20afbe4397e51b717a7c1ad3095e79aee48c835eebd9237a3e8a16951ade1fe0e66e981e30ea269849fcb6ba03d838da37f524fabd2a557474194a2e2604fa@18.221.100.27:31002,enode://ce1e0d8e0500cb5c0ac56bdcdafb2d6320c3a2c5125b5ccf12f5dfc9b47ee74acbcafc32559017613136c9c36a0ce74ba4f83b7fb8244f099f3b15708d9d3129@3.23.75.47:31000,enode://1b026a5eb0ae74300f58987d235ef0e3a550df963345cb3574be3b0b54378bd11f14dfd515a8976f2c2d2826090e9507b8ccc24f896a9ffffffcabcfd996a733@3.129.120.128:31001
|
||||
- --datadir=/root/.ethereum
|
||||
- --db.engine=pebble
|
||||
- --gcmode=full
|
||||
- --maxpeers=50
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --nat=extip:${IP}
|
||||
- --port=14190
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
- --state.scheme=path
|
||||
- --syncmode=snap
|
||||
- --http
|
||||
- --http.addr=0.0.0.0
|
||||
- --http.api=eth,net,web3,debug,admin,txpool
|
||||
- --http.port=8545
|
||||
- --http.vhosts=*
|
||||
- --ws
|
||||
- --ws.addr=0.0.0.0
|
||||
- --ws.api=eth,net,web3,debug,admin,txpool
|
||||
- --ws.origins=*
|
||||
- --ws.port=8545
|
||||
- --authrpc.addr=0.0.0.0
|
||||
- --authrpc.jwtsecret=/jwtsecret
|
||||
- --authrpc.vhosts=*
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_SEPOLIA_GETH_PRUNED_PEBBLE_PATH_DATA:-linea-sepolia-geth-pruned-pebble-path}:/root/.ethereum
|
||||
- ./linea/sepolia:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
- /slowdisk:/slowdisk
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=6060
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
- traefik.enable=true
|
||||
- traefik.http.middlewares.linea-sepolia-geth-pruned-pebble-path-stripprefix.stripprefix.prefixes=/linea-sepolia-geth
|
||||
- traefik.http.services.linea-sepolia-geth-pruned-pebble-path.loadbalancer.server.port=8545
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-pruned-pebble-path.entrypoints=websecure}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-pruned-pebble-path.tls.certresolver=myresolver}
|
||||
- ${NO_SSL:-traefik.http.routers.linea-sepolia-geth-pruned-pebble-path.rule=Host(`$DOMAIN`) && (Path(`/linea-sepolia-geth`) || Path(`/linea-sepolia-geth/`))}
|
||||
- ${NO_SSL:+traefik.http.routers.linea-sepolia-geth-pruned-pebble-path.rule=Path(`/linea-sepolia-geth`) || Path(`/linea-sepolia-geth/`)}
|
||||
- traefik.http.routers.linea-sepolia-geth-pruned-pebble-path.middlewares=linea-sepolia-geth-pruned-pebble-path-stripprefix, ipallowlist
|
||||
|
||||
linea-sepolia-geth-node:
|
||||
build:
|
||||
context: ./linea
|
||||
dockerfile: maru.Dockerfile
|
||||
args:
|
||||
MARU_IMAGE: ${LINEA_SEPOLIA_MARU_IMAGE:-consensys/maru}
|
||||
MARU_VERSION: ${LINEA_SEPOLIA_MARU_VERSION:-v1.0.0-20260108114606-36f5e2f}
|
||||
ports:
|
||||
- 19190:19190
|
||||
- 19190:19190/udp
|
||||
expose:
|
||||
- 8080
|
||||
environment:
|
||||
- EL_HOST=linea-sepolia-geth
|
||||
- IP=${IP}
|
||||
- L1_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- P2P_PORT=19190
|
||||
- SEQUENCER=https://rpc.sepolia.linea.build
|
||||
entrypoint: [/bin/bash, -c]
|
||||
command:
|
||||
- |
|
||||
envsubst < /config/maru/config.toml.template > /config.toml
|
||||
exec java -Dlog4j2.configurationFile=/config/maru/log4j.xml -jar /opt/consensys/maru/maru.jar --network=linea-sepolia --config=/config.toml "$@"
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- chains
|
||||
volumes:
|
||||
- ${LINEA_SEPOLIA_GETH_PRUNED_PEBBLE_PATH__MARU_DATA:-linea-sepolia-geth-pruned-pebble-path_maru}:/opt/maru/data
|
||||
- ./linea/sepolia:/config
|
||||
- .jwtsecret:/jwtsecret:ro
|
||||
logging: *logging-defaults
|
||||
labels:
|
||||
- prometheus-scrape.enabled=true
|
||||
- prometheus-scrape.port=9090
|
||||
- prometheus-scrape.path=/debug/metrics/prometheus
|
||||
|
||||
volumes:
|
||||
linea-sepolia-geth-pruned-pebble-path:
|
||||
linea-sepolia-geth-pruned-pebble-path_maru:
|
||||
|
||||
x-upstreams:
|
||||
- id: $${ID}
|
||||
labels:
|
||||
provider: $${PROVIDER}
|
||||
connection:
|
||||
generic:
|
||||
rpc:
|
||||
url: $${RPC_URL}
|
||||
ws:
|
||||
frameSize: 20Mb
|
||||
msgSize: 50Mb
|
||||
url: $${WS_URL}
|
||||
chain: linea-sepolia
|
||||
method-groups:
|
||||
enabled:
|
||||
- debug
|
||||
- filter
|
||||
methods:
|
||||
disabled:
|
||||
# not compatible with path state scheme
|
||||
- name: debug_traceBlockByHash
|
||||
enabled:
|
||||
- name: txpool_content # TODO: should be disabled for rollup nodes
|
||||
# standard geth only
|
||||
- name: debug_getRawBlock
|
||||
- name: debug_getRawTransaction
|
||||
- name: debug_getRawReceipts
|
||||
- name: debug_getRawHeader
|
||||
- name: debug_getBadBlocks
|
||||
# non standard geth only slightly dangerous
|
||||
- name: debug_intermediateRoots
|
||||
- name: debug_dumpBlock
|
||||
# standard geth and erigon
|
||||
- name: debug_accountRange
|
||||
- name: debug_getModifiedAccountsByNumber
|
||||
- name: debug_getModifiedAccountsByHash
|
||||
# non standard geth and erigon
|
||||
- name: eth_getRawTransactionByHash
|
||||
- name: eth_getRawTransactionByBlockHashAndIndex
|
||||
...
|
||||
@@ -64,7 +64,7 @@ services:
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --network=garfield
|
||||
- --networkid=48898
|
||||
- --nodiscover
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
@@ -113,11 +113,11 @@ services:
|
||||
- 17296:17296
|
||||
- 17296:17296/udp
|
||||
environment:
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_HOLESKY_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_HOLESKY_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_HOLESKY_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_HOLESKY_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_HOLESKY_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_SEPOLIA_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_SEPOLIA_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_SEPOLIA_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_SEPOLIA_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L2_ENGINE_AUTH=/jwtsecret
|
||||
- OP_NODE_L2_ENGINE_RPC=http://zircuit-garfield-archive:8551
|
||||
- OP_NODE_L2_SKIP_SYNC_START_CHECK=true
|
||||
@@ -126,7 +126,8 @@ services:
|
||||
- OP_NODE_METRICS_ENABLED=true
|
||||
- OP_NODE_METRICS_PORT=7300
|
||||
- OP_NODE_METRIC_ENABLED=true
|
||||
- OP_NODE_NETWORK=garfield
|
||||
- OP_NODE_NETWORK=testnet
|
||||
- OP_NODE_OVERRIDE_PECTRABLOBSCHEDULE=1742486400
|
||||
- OP_NODE_P2P_ADVERTISE_IP=${IP}
|
||||
- OP_NODE_P2P_LISTEN_IP=0.0.0.0
|
||||
- OP_NODE_P2P_LISTEN_TCP_PORT=17296
|
||||
|
||||
@@ -64,7 +64,7 @@ services:
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --network=garfield
|
||||
- --networkid=48898
|
||||
- --nodiscover
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
@@ -113,11 +113,11 @@ services:
|
||||
- 16723:16723
|
||||
- 16723:16723/udp
|
||||
environment:
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_HOLESKY_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_HOLESKY_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_HOLESKY_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_HOLESKY_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_HOLESKY_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_SEPOLIA_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_SEPOLIA_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_SEPOLIA_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_SEPOLIA_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L2_ENGINE_AUTH=/jwtsecret
|
||||
- OP_NODE_L2_ENGINE_RPC=http://zircuit-garfield-archive:8551
|
||||
- OP_NODE_L2_SKIP_SYNC_START_CHECK=true
|
||||
@@ -126,7 +126,8 @@ services:
|
||||
- OP_NODE_METRICS_ENABLED=true
|
||||
- OP_NODE_METRICS_PORT=7300
|
||||
- OP_NODE_METRIC_ENABLED=true
|
||||
- OP_NODE_NETWORK=garfield
|
||||
- OP_NODE_NETWORK=testnet
|
||||
- OP_NODE_OVERRIDE_PECTRABLOBSCHEDULE=1742486400
|
||||
- OP_NODE_P2P_ADVERTISE_IP=${IP}
|
||||
- OP_NODE_P2P_LISTEN_IP=0.0.0.0
|
||||
- OP_NODE_P2P_LISTEN_TCP_PORT=16723
|
||||
|
||||
@@ -64,7 +64,7 @@ services:
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --network=garfield
|
||||
- --networkid=48898
|
||||
- --nodiscover
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
@@ -113,11 +113,11 @@ services:
|
||||
- 17397:17397
|
||||
- 17397:17397/udp
|
||||
environment:
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_HOLESKY_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_HOLESKY_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_HOLESKY_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_HOLESKY_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_HOLESKY_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_SEPOLIA_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_SEPOLIA_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_SEPOLIA_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_SEPOLIA_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L2_ENGINE_AUTH=/jwtsecret
|
||||
- OP_NODE_L2_ENGINE_RPC=http://zircuit-garfield:8551
|
||||
- OP_NODE_L2_SKIP_SYNC_START_CHECK=true
|
||||
@@ -126,7 +126,8 @@ services:
|
||||
- OP_NODE_METRICS_ENABLED=true
|
||||
- OP_NODE_METRICS_PORT=7300
|
||||
- OP_NODE_METRIC_ENABLED=true
|
||||
- OP_NODE_NETWORK=garfield
|
||||
- OP_NODE_NETWORK=testnet
|
||||
- OP_NODE_OVERRIDE_PECTRABLOBSCHEDULE=1742486400
|
||||
- OP_NODE_P2P_ADVERTISE_IP=${IP}
|
||||
- OP_NODE_P2P_LISTEN_IP=0.0.0.0
|
||||
- OP_NODE_P2P_LISTEN_TCP_PORT=17397
|
||||
|
||||
@@ -64,7 +64,7 @@ services:
|
||||
- --metrics
|
||||
- --metrics.addr=0.0.0.0
|
||||
- --metrics.port=6060
|
||||
- --network=garfield
|
||||
- --networkid=48898
|
||||
- --nodiscover
|
||||
- --rpc.gascap=600000000
|
||||
- --rpc.txfeecap=0
|
||||
@@ -113,11 +113,11 @@ services:
|
||||
- 15072:15072
|
||||
- 15072:15072/udp
|
||||
environment:
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_HOLESKY_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_HOLESKY_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_HOLESKY_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_HOLESKY_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_HOLESKY_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L1_BEACON=${ETHEREUM_SEPOLIA_BEACON_REST}
|
||||
- OP_NODE_L1_BEACON_ARCHIVER=${ETHEREUM_SEPOLIA_BEACON_ARCHIVER}
|
||||
- OP_NODE_L1_ETH_RPC=${ETHEREUM_SEPOLIA_EXECUTION_RPC}
|
||||
- OP_NODE_L1_RPC_KIND=${ETHEREUM_SEPOLIA_EXECUTION_KIND:-basic}
|
||||
- OP_NODE_L1_TRUST_RPC=${ETHEREUM_SEPOLIA_EXECUTION_TRUST:-false}
|
||||
- OP_NODE_L2_ENGINE_AUTH=/jwtsecret
|
||||
- OP_NODE_L2_ENGINE_RPC=http://zircuit-garfield:8551
|
||||
- OP_NODE_L2_SKIP_SYNC_START_CHECK=true
|
||||
@@ -126,7 +126,8 @@ services:
|
||||
- OP_NODE_METRICS_ENABLED=true
|
||||
- OP_NODE_METRICS_PORT=7300
|
||||
- OP_NODE_METRIC_ENABLED=true
|
||||
- OP_NODE_NETWORK=garfield
|
||||
- OP_NODE_NETWORK=testnet
|
||||
- OP_NODE_OVERRIDE_PECTRABLOBSCHEDULE=1742486400
|
||||
- OP_NODE_P2P_ADVERTISE_IP=${IP}
|
||||
- OP_NODE_P2P_LISTEN_IP=0.0.0.0
|
||||
- OP_NODE_P2P_LISTEN_TCP_PORT=15072
|
||||
|
||||
@@ -56,14 +56,17 @@ services:
|
||||
- --eth-node=${ETHEREUM_MAINNET_EXECUTION_WS}
|
||||
- --http
|
||||
- --http-host=0.0.0.0
|
||||
- --http-port=6060
|
||||
- --metrics
|
||||
- --metrics-host=0.0.0.0
|
||||
- --network=mainnet
|
||||
- --p2p
|
||||
- --p2p-addr=/ip4/0.0.0.0/tcp/13985
|
||||
- --p2p-feeder-node
|
||||
- --p2p-public-addr=/ip4/${IP}/tcp/13985
|
||||
- --ws
|
||||
- --ws-host=0.0.0.0
|
||||
- --ws-port=6061
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
|
||||
@@ -56,14 +56,17 @@ services:
|
||||
- --eth-node=${ETHEREUM_SEPOLIA_EXECUTION_WS}
|
||||
- --http
|
||||
- --http-host=0.0.0.0
|
||||
- --http-port=6060
|
||||
- --metrics
|
||||
- --metrics-host=0.0.0.0
|
||||
- --network=sepolia
|
||||
- --p2p
|
||||
- --p2p-addr=/ip4/0.0.0.0/tcp/14344
|
||||
- --p2p-feeder-node
|
||||
- --p2p-public-addr=/ip4/${IP}/tcp/14344
|
||||
- --ws
|
||||
- --ws-host=0.0.0.0
|
||||
- --ws-port=6061
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 5m
|
||||
networks:
|
||||
|
||||
@@ -23,17 +23,34 @@ for path in $pathlist; do
|
||||
RPC_URL="https://$DOMAIN/$path"
|
||||
response_file=$(mktemp)
|
||||
|
||||
http_status_code=$(curl --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}' "$RPC_URL")
|
||||
# Detect Starknet vs Ethereum based on path
|
||||
if echo "$path" | grep -qi "starknet"; then
|
||||
rpc_method='{"jsonrpc":"2.0","method":"starknet_getBlockWithTxHashes","params":["latest"],"id":1}'
|
||||
is_starknet=true
|
||||
else
|
||||
rpc_method='{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}'
|
||||
is_starknet=false
|
||||
fi
|
||||
|
||||
http_status_code=$(curl --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data "$rpc_method" "$RPC_URL")
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
if [[ $http_status_code -eq 200 ]]; then
|
||||
response=$(cat "$response_file")
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
current_timestamp=$(date +%s)
|
||||
age=$((current_timestamp - ("16#${latest_block_timestamp#0x}")))
|
||||
|
||||
|
||||
if $is_starknet; then
|
||||
# Starknet returns decimal timestamp
|
||||
latest_block_timestamp_decimal=$(echo "$response" | jq -r '.result.timestamp')
|
||||
age=$((current_timestamp - latest_block_timestamp_decimal))
|
||||
else
|
||||
# Ethereum returns hex timestamp
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
age=$((current_timestamp - (16#${latest_block_timestamp#0x})))
|
||||
fi
|
||||
|
||||
echo "$age"
|
||||
|
||||
|
||||
if (( age < ${2:-3600} )); then
|
||||
exit 0
|
||||
else
|
||||
|
||||
@@ -34,32 +34,71 @@ for path in $pathlist; do
|
||||
if $include; then
|
||||
RPC_URL="$PROTO://$DOMAIN/$path"
|
||||
|
||||
# Detect Starknet vs Ethereum based on path
|
||||
if echo "$path" | grep -qi "starknet"; then
|
||||
is_starknet=true
|
||||
else
|
||||
is_starknet=false
|
||||
fi
|
||||
|
||||
ref=''
|
||||
if [ -n "$2" ]; then
|
||||
ref="$2"
|
||||
else
|
||||
chain_id_response=$(curl -L --ipv4 -m 1 -s -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}' $RPC_URL)
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
chain_id=$(echo "$chain_id_response" | jq -r '.result' 2>/dev/null)
|
||||
if $is_starknet; then
|
||||
# Starknet chain ID detection
|
||||
chain_id_response=$(curl -L --ipv4 -m 1 -s -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"starknet_chainId","params":[],"id":1}' $RPC_URL)
|
||||
|
||||
# echo "$RPC_URL: $chain_id"
|
||||
|
||||
if [[ "$chain_id" =~ ^0x[0-9a-fA-F]+$ ]]; then
|
||||
chain_id_decimal=$((16#${chain_id#0x}))
|
||||
ref=$($BASEPATH/reference-rpc-endpoint.sh $chain_id_decimal)
|
||||
else
|
||||
echo "error"
|
||||
exit 1
|
||||
fi
|
||||
else
|
||||
echo "error"
|
||||
exit 1
|
||||
fi
|
||||
if [ $? -eq 0 ]; then
|
||||
chain_id=$(echo "$chain_id_response" | jq -r '.result' 2>/dev/null)
|
||||
|
||||
# Map Starknet chain IDs to reference endpoints
|
||||
# Chain ID can be plain string or hex-encoded ASCII
|
||||
case "$chain_id" in
|
||||
"SN_MAIN"|"0x534e5f4d41494e")
|
||||
ref=$($BASEPATH/reference-rpc-endpoint.sh 23448594291968336)
|
||||
;;
|
||||
"SN_SEPOLIA"|"0x534e5f5345504f4c4941")
|
||||
ref=$($BASEPATH/reference-rpc-endpoint.sh 393402133025997800000000)
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown starknet chain $chain_id"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
else
|
||||
echo "error"
|
||||
exit 1
|
||||
fi
|
||||
else
|
||||
# Ethereum chain ID detection
|
||||
chain_id_response=$(curl -L --ipv4 -m 1 -s -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}' $RPC_URL)
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
chain_id=$(echo "$chain_id_response" | jq -r '.result' 2>/dev/null)
|
||||
|
||||
# echo "$RPC_URL: $chain_id"
|
||||
|
||||
if [[ "$chain_id" =~ ^0x[0-9a-fA-F]+$ ]]; then
|
||||
chain_id_decimal=$((16#${chain_id#0x}))
|
||||
ref=$($BASEPATH/reference-rpc-endpoint.sh $chain_id_decimal)
|
||||
else
|
||||
echo "error"
|
||||
exit 1
|
||||
fi
|
||||
else
|
||||
echo "error"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
# Call the health check script with RPC_URL and ref
|
||||
$BASEPATH/check-health.sh "$RPC_URL" $ref
|
||||
# Call the health check script with RPC_URL, ref, and starknet flag
|
||||
if $is_starknet; then
|
||||
$BASEPATH/check-health.sh "$RPC_URL" --starknet $ref
|
||||
else
|
||||
$BASEPATH/check-health.sh "$RPC_URL" $ref
|
||||
fi
|
||||
exit $?
|
||||
fi
|
||||
done
|
||||
|
||||
25
timestamp.sh
25
timestamp.sh
@@ -30,18 +30,33 @@ for path in $pathlist; do
|
||||
RPC_URL="$PROTO://$DOMAIN/$path"
|
||||
response_file=$(mktemp)
|
||||
|
||||
http_status_code=$(curl -L --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}' $RPC_URL)
|
||||
# Detect Starknet vs Ethereum based on path
|
||||
if echo "$path" | grep -qi "starknet"; then
|
||||
rpc_method='{"jsonrpc":"2.0","method":"starknet_getBlockWithTxHashes","params":["latest"],"id":1}'
|
||||
is_starknet=true
|
||||
else
|
||||
rpc_method='{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["latest", false],"id":1}'
|
||||
is_starknet=false
|
||||
fi
|
||||
|
||||
http_status_code=$(curl -L --ipv4 -m 1 -s -X POST -w "%{http_code}" -o "$response_file" -H "Content-Type: application/json" --data "$rpc_method" $RPC_URL)
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
|
||||
|
||||
if [[ $http_status_code -eq 200 ]]; then
|
||||
response=$(cat "$response_file")
|
||||
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal=$((16#${latest_block_timestamp#0x}))
|
||||
if $is_starknet; then
|
||||
# Starknet returns decimal timestamp
|
||||
latest_block_timestamp_decimal=$(echo "$response" | jq -r '.result.timestamp')
|
||||
else
|
||||
# Ethereum returns hex timestamp
|
||||
latest_block_timestamp=$(echo "$response" | jq -r '.result.timestamp')
|
||||
latest_block_timestamp_decimal=$((16#${latest_block_timestamp#0x}))
|
||||
fi
|
||||
|
||||
echo "$latest_block_timestamp_decimal"
|
||||
|
||||
|
||||
exit 0;
|
||||
fi
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user