Skip to content

shaman007/connectivity-exporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

connectivity-exporter

image FOSSA Status

Inspired by this post: https://antonz.org/is-online/

Prometheus compatible exporter that checks connectivity to given HTTP URI. Default config.yaml checks public internet services, however, you can use it to check API status of your own applications. Don't abuse public services! There is fancy hompage that shows current situation.

  • /metrics show Prometheus compatible metrics
  • / homepage that shows current situation

Usage

Sample config:

endpoints:
  - url: https://google.com/generate_204
    expect: 204
  - url: http://captive.apple.com/hotspot-detect.html
    expect: 200

and then use it:

python check.py --config config.yaml --port 9000 --interval 60

Or via environment:

export CONFIG=config.yaml
export PORT=9090
export INTERVAL=30
python check.py

then scrape:

- job_name: connectivity-exporter
  static_configs:
    - targets: connectivity-exporter.default.svc.cluster.local/metrics:9090

Deployment

Sample Dokerfile and K8S deployment are provided.

Image: harbor.andreybondarenko.com/library/connectivity-exporter:latest

ToDo

Fancy hompage that shows current situation.

License

FOSSA Status

About

Prometheus compatible exporter that checks connectivity to given HTTP URI

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 2

  •  
  •