Skip to content

Small Docker Hub Rate Limits Exporter for Prometheus

License

Notifications You must be signed in to change notification settings

nk-designz/grafzahl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Grafzahl


Monitor your Dockerhub Rate-Limits in Prometheus on Port 6969! Nice!

Options

Flag Environment Yaml
--username=<username> GRAFZAHL_USERNAME username: <USERNAME>
--password=<password> GRAFZAHL_PASSWORD password: <PASSWORD>

Path: /etc/grafzahl.yaml or ~/grafzahl.yaml

Metrics

 HELP docker_hub_rate_limit The maximal pulls for this account.
# TYPE docker_hub_rate_limit gauge
docker_hub_rate_limit 0
# HELP docker_hub_rate_limit_remaining The remaining pulls for this account.
# TYPE docker_hub_rate_limit_remaining gauge
docker_hub_rate_limit_remaining 0

metrics

Run

Docker

  1. Start the container
    docker run --restart=always \
      -p 6969:6969 \
      -e "GRAFZAHL_PASSWORD=<PASSWORD>" \
      -e "GRAFZAHL_USERNAME=<USERNAME>" \
      me/grafzahl:1.25.3
  2. Pet nearby cat.

Native

  1. Move the binary into PATH
    sudo install grafzahl
  2. Add the config
    vim /etc/grafzahl.yaml
  3. Run the process
    ./grafzahl &
    A service for systemd would be welcome
  4. Pet nearby cat nonetheless.

Build

Go

go get -v
go build .

Docker

docker build . -t <user>/grafzahl:<version>
docker push <user>/grafzahl:<version>