Skip to content

Commit 6500050

Browse files
Merge branch 'release' into geth-allow-pre155
2 parents 36427d6 + 45f7a40 commit 6500050

File tree

13 files changed

+407
-164
lines changed

13 files changed

+407
-164
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,10 @@ user_fee_token_deployer: 0x2AC5278D230f88B481bBE4A94751d7188ef48Ca2
124124

125125
While not a named account, 0x3f1eae7d46d88f08fc2f8ed27fcb2ab183eb2d0e is funded on all test chains.
126126

127+
## Metrics
128+
129+
To run the metrics stack (Prometheus + Grafana) read the instructions in the [metrics/README.md](metrics/README.md) file.
130+
127131
## Contact
128132

129133
Discord - [Arbitrum](https://discord.com/invite/5KE54JwyTs)

docker-compose.yaml

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ services:
4747
- "127.0.0.1:6379:6379"
4848

4949
geth:
50-
image: ethereum/client-go:v1.14.13
50+
image: ethereum/client-go:v1.16.4
5151
ports:
5252
- "127.0.0.1:8545:8545"
5353
- "127.0.0.1:8551:8551"
@@ -89,7 +89,7 @@ services:
8989
# a deterministic set of validators
9090
# TODO: Make num validators customizable
9191
create_beacon_chain_genesis:
92-
image: "gcr.io/prysmaticlabs/prysm/cmd/prysmctl:latest"
92+
image: "gcr.io/prysmaticlabs/prysm/cmd/prysmctl:v6.1.1"
9393
command:
9494
- testnet
9595
- generate-genesis
@@ -108,7 +108,7 @@ services:
108108
# The account used in go-ethereum is set as the suggested fee recipient for transactions
109109
# proposed via the validators attached to the beacon node.
110110
prysm_beacon_chain:
111-
image: "gcr.io/prysmaticlabs/prysm/beacon-chain:stable"
111+
image: "gcr.io/prysmaticlabs/prysm/beacon-chain:v6.1.1"
112112
command:
113113
- --datadir=/consensus/beacondata
114114
- --rpc-port=5000
@@ -382,7 +382,10 @@ services:
382382
NITRO_CONTRACTS_BRANCH: ${NITRO_CONTRACTS_BRANCH:-}
383383
volumes:
384384
- "config:/config"
385-
- /var/run/docker.sock:/var/run/docker.sock
385+
- "/var/run/docker.sock:/var/run/docker.sock"
386+
- "contracts:/contracts"
387+
- "contracts-local:/contracts-local"
388+
- "referenceda-provider-data:/referenceda-provider"
386389

387390
datool:
388391
image: nitro-node-dev-testnode
@@ -392,7 +395,7 @@ services:
392395
- "das-committee-a-data:/das-committee-a"
393396
- "das-committee-b-data:/das-committee-b"
394397
- "das-mirror-data:/das-mirror"
395-
command:
398+
- "referenceda-provider-data:/referenceda-provider"
396399

397400
das-committee-a:
398401
pid: host # allow debugging
@@ -432,6 +435,20 @@ services:
432435
command:
433436
- --conf.file=/config/l2_das_mirror.json
434437

438+
referenceda-provider:
439+
pid: host # allow debugging
440+
image: nitro-node-dev-testnode
441+
entrypoint: /usr/local/bin/daprovider
442+
ports:
443+
- "127.0.0.1:9880:9880"
444+
volumes:
445+
- "config:/config"
446+
- "referenceda-provider-data:/data"
447+
- "contracts:/contracts"
448+
- "contracts-local:/contracts-local"
449+
command:
450+
- --conf.file=/config/referenceda_provider.json
451+
435452
timeboost-auctioneer:
436453
pid: host # allow debugging
437454
image: nitro-node-dev-testnode
@@ -482,4 +499,7 @@ volumes:
482499
das-committee-a-data:
483500
das-committee-b-data:
484501
das-mirror-data:
502+
referenceda-provider-data:
485503
timeboost-auctioneer-data:
504+
contracts:
505+
contracts-local:

metrics/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Arbitrum Nitro Metrics
2+
3+
You can run this docker compose file it will run
4+
5+
- prometheus
6+
- grafana
7+
- setup the default dashboard
8+
9+
The default username/password is `admin`/`admin`.
10+
11+
## Run the metrics services
12+
13+
Simply start docker compose in this `metrics/` folder:
14+
15+
```sh
16+
docker compose up
17+
```
18+
19+
## Enable metrics on Nitro node
20+
21+
Don't forget to run the Nitro node with metrics exporting on, to do so add the following flags to your Nitro node startup command:
22+
23+
```sh
24+
--metrics --metrics-server.addr=0.0.0.0
25+
```
26+
27+
> ⚠️ Warning: Using 0.0.0.0 is recommended for cross-platform compatibility,
28+
especially when accessing metrics from Docker, Linux, WSL, or remote containers.
29+
30+
## View the Dashboard
31+
32+
View the dashboard at http://localhost:3000
33+
34+
## How to add more grafana dashboards
35+
36+
To add more grafana dashboards you can drop json files into the `grafana/dashboards/` folder.

metrics/compose.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
services:
2+
prometheus:
3+
image: prom/prometheus
4+
container_name: prometheus
5+
command:
6+
- '--config.file=/etc/prometheus/prometheus.yaml'
7+
restart: unless-stopped
8+
volumes:
9+
- ./prometheus:/etc/prometheus
10+
- prometheus_data:/prometheus
11+
ports:
12+
- 9090:9090
13+
extra_hosts:
14+
- "host.docker.internal:host-gateway"
15+
grafana:
16+
image: grafana/grafana
17+
container_name: grafana
18+
restart: unless-stopped
19+
volumes:
20+
- ./grafana/datasource.yaml:/etc/grafana/provisioning/datasources/datasource.yaml
21+
- ./grafana/dashboard.yaml:/etc/grafana/provisioning/dashboards/main.yaml
22+
- ./grafana/dashboards:/var/lib/grafana/dashboards
23+
ports:
24+
- 3000:3000
25+
extra_hosts:
26+
- "host.docker.internal:host-gateway"
27+
28+
volumes:
29+
prometheus_data:
30+
31+
networks: {}

metrics/grafana/dashboard.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
apiVersion: 1
2+
3+
providers:
4+
- name: "Offchain Labs"
5+
orgId: 1
6+
type: file
7+
disableDeletion: false
8+
updateIntervalSeconds: 10
9+
allowUiUpdates: false
10+
options:
11+
path: /var/lib/grafana/dashboards
12+
foldersFromFilesStructure: true
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"annotations":{"list":[{"builtIn":1,"datasource":{"type":"grafana","uid":"-- Grafana --"},"enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"editable":true,"fiscalYearStartMonth":0,"graphTooltip":0,"id":0,"links":[],"panels":[{"datasource":{"type":"prometheus","uid":"PBFA97CFB590B2093"},"fieldConfig":{"defaults":{"color":{"mode":"palette-classic"},"custom":{"axisBorderShow":false,"axisCenteredZero":false,"axisColorMode":"text","axisLabel":"","axisPlacement":"auto","barAlignment":0,"barWidthFactor":0.6,"drawStyle":"line","fillOpacity":0,"gradientMode":"none","hideFrom":{"legend":false,"tooltip":false,"viz":false},"insertNulls":false,"lineInterpolation":"linear","lineWidth":1,"pointSize":5,"scaleDistribution":{"type":"linear"},"showPoints":"auto","showValues":false,"spanNulls":false,"stacking":{"group":"A","mode":"none"},"thresholdsStyle":{"mode":"off"}},"mappings":[],"thresholds":{"mode":"absolute","steps":[{"color":"green","value":0},{"color":"red","value":80}]}},"overrides":[]},"gridPos":{"h":8,"w":12,"x":0,"y":0},"id":1,"options":{"legend":{"calcs":[],"displayMode":"list","placement":"bottom","showLegend":true},"tooltip":{"hideZeros":false,"mode":"single","sort":"none"}},"pluginVersion":"12.2.0","targets":[{"datasource":{"type":"prometheus","uid":"PBFA97CFB590B2093"},"editorMode":"builder","expr":"arb_block_transactions_count","legendFormat":"__auto","range":true,"refId":"A"}],"title":"Arb Block Transactions Count","type":"timeseries"}],"preload":false,"refresh":"5s","schemaVersion":42,"tags":[],"templating":{"list":[]},"time":{"from":"now-30m","to":"now"},"timepicker":{},"timezone":"browser","title":"Example dashboard","uid":"adq7lsl","version":2}

metrics/grafana/datasource.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
apiVersion: 1
2+
3+
datasources:
4+
- name: Prometheus
5+
type: prometheus
6+
url: http://host.docker.internal:9090
7+
isDefault: true
8+
access: proxy
9+
editable: true

metrics/prometheus/prometheus.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
global:
2+
scrape_interval: 4s
3+
scrape_timeout: 4s
4+
evaluation_interval: 10s
5+
6+
scrape_configs:
7+
- job_name: "nitro"
8+
metrics_path: /debug/metrics/prometheus
9+
static_configs:
10+
- targets:
11+
- host.docker.internal:6070
12+
labels:
13+
instance: local_node

0 commit comments

Comments
 (0)