/bitcanna-prometheus-exporter

Prometheus exporter for BitCanna Core nodes

Primary LanguagePythonBSD 3-Clause "New" or "Revised" LicenseBSD-3-Clause

BitCanna Core Prometheus Exporter

A Prometheus exporter for [BitCanna Core] nodes written in python and packaged for running as a container.

A rudimentary Grafana dashboard is available in the dashboard/bitcoin-grafana.json file.

The main script is a modified version of bitcoin-monitor.py, updated to remove the need for the bitcoin-cli binary, packaged into a Docker image, and expanded to export additional metrics.

Run the container

docker run \
    --name=bitcanna-exporter \
    -p 8443:8443 \
    -e BITCANNA_RPC_HOST=bitcanna-node \
    -e BITCANNA_RPC_USER=alice \
    -e BITCANNA_RPC_PASSWORD=DONT_USE_THIS_YOU_WILL_GET_ROBBED_8ak1gI25KFTvjovL3gAM967mies3E= \
    jvstein/bitcanna-prometheus-exporter:v0.5.0

Basic Testing

There's a docker-compose.yml file in the repository that references a test bitcanna node. To test changes to the exporter in docker, run the following commands.

docker-compose down
docker-compose build
docker-compose up

If you see a lot of ConnectionRefusedError errors, run chmod og+r test-bitcanna.conf.

See the CHANGELOG.md file for changes.