Skip to content

loafoe/prometheus-solaxcloud-exporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

prometheus-solaxcloud-exporter

Prometheus exporter for SolaxCloud data. Resolution is fixed at 5 minutes.

If you prefer real-time data, please have a look at the promethues-solaxrt-exporter project instead

Install

Using Go 1.18 or newer

go install github.com/loafoe/prometheus-solaxcloud-exporter@latest

Usage

Set credentials

export SOLAXCLOUD_SN=your-sn
export SOLAXCLOUD_TOKEN_ID=your-token

Run exporter

prometheus-solaxcloud-exporter -listen 0.0.0.0:8887

Ship to prometheus

You can use something like Grafana-agent to ship data to a remote write endpoint. Example:

metrics:
  configs:
    - name: default
      scrape_configs:
        - job_name: 'solaxcloud_exporter'
          scrape_interval: 2m
          static_configs:
            - targets: ['localhost:8887']
      remote_write:
        - url: https://prometheus.example.com/api/v1/write
          basic_auth:
            username: scraper
            password: S0m3pAssW0rdH3Re

License

License is MIT