Skip to content

fengxsong/aliyun_exporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Aliyun Exporter

a prometheus exporter for Aliyun CloudMonitor service. Written in Golang, inspired by aliyun_exporter.

Develop

git clone https://github.com/fengxsong/aliyun_exporter
cd aliyun_exporter
make tidy

Usage

make bin
# generate example of config
./build/_output/bin/aliyun_exporter generate-example-config --accesskey xxxx ----accesskeysecret xxxx
# run http metrics handler
./build/_output/bin/aliyun_exporter serve [--config=/path/of/config]

Create a prometheus scrape job

- job_name: 'aliyun_exporter'
  scrape_interval: 60s
  scrape_timeout: 60s
  static_configs:
  - targets: ['aliyun_exporter:9527']
    labels:
      account_name: xxxx
      provider: aliyun # or aliyun_jst

Prometheus rules sample

sample file

Limitation

  • an exporter instance can only scrape metrics from single region

TODO

  • grafana dashboard

Ref