Prerequisites
- Docker and Docker Compose are installed on the host that runs Prometheus.
- MyTonCtrl installed and running on the node that emits metrics.
Deploy Prometheus and Pushgateway
- In an empty directory, create
docker-compose.yml:
- Create
prometheus.ymlalongside it:
- Start the stack and confirm the container status:
Configure MyTonCtrl to push metrics
- Open the MyTonCtrl console:
- Enable Prometheus mode:
- Point MyTonCtrl to the Pushgateway (include a job name):
<PUSHGATEWAY_HOST> — host running the Pushgateway (use 127.0.0.1 when MyTonCtrl and Docker run on the same machine).
<JOB_NAME> — unique label for this node, for example validator1.
Use unique job namesDo not reuse the same
JOB_NAME across nodes when scraped by one Prometheus instance, or metrics collide.Verify metrics
- Pushgateway: open
http://<PUSHGATEWAY_HOST>:9091and confirm metrics appear under<JOB_NAME>. - Prometheus targets: open
http://<PROMETHEUS_HOST>:9090/targetsand check thatmytonctrl_pushgatewayshowsUP. - Prometheus graph: query
mytonctrl_syncedor other MyTonCtrl metrics athttp://<PROMETHEUS_HOST>:9090/graph.