Skip to content

Commit

Permalink
workers point to corret url. Make prometheus scrape workers (MystenLa…
Browse files Browse the repository at this point in the history
  • Loading branch information
akichidis authored Aug 3, 2022
1 parent 552a2db commit 10195ce
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 8 additions & 2 deletions narwhal/Docker/gen.validators.sh
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,18 @@ cp -r templates/{grafana,prometheus} ${target}/
t=$(($num - 1))
for i in $(seq -f %02g 0 ${t})
do
scrape="primary_${i}:8010"
scrape_primary="primary_${i}:8010"
scrape_worker="worker_${i}:8010"
cat >> ${target}/prometheus/prometheus.yml <<EOF
- job_name: 'primary_${i}'
scrape_interval: 10s
static_configs:
- targets: ['${scrape}']
- targets: ['${scrape_primary}']
- job_name: 'worker_${i}'
scrape_interval: 10s
static_configs:
- targets: ['${scrape_worker}']
EOF
done
6 changes: 3 additions & 3 deletions narwhal/Docker/scripts/gen.committee.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ def main():
"stake": 1,
"workers": {
"0": {
"primary_to_worker": "/dns/worker_00/tcp/4000/http",
"transactions": "/dns/worker_00/tcp/4001/http",
"worker_to_worker": "/dns/worker_00/tcp/4002/http"
"primary_to_worker": "/dns/worker_{:02d}/tcp/4000/http".format(i),
"transactions": "/dns/worker_{:02d}/tcp/4001/http".format(i),
"worker_to_worker": "/dns/worker_{:02d}/tcp/4002/http".format(i)
}
}
}
Expand Down

0 comments on commit 10195ce

Please sign in to comment.