{"repo":"wywywywy/docker_stats_exporter","free":true,"listed":false,"github":"https://github.com/wywywywy/docker_stats_exporter","clone":"git clone https://github.com/wywywywy/docker_stats_exporter.git","description":"Docker Stats exporter for Prometheus","language":"JavaScript","stars":61,"topics":["prometheus","prometheus-exporter","docker","docker-stats","nodejs"],"license":"Apache-2.0","category":"deployment-docker-iac","readme_excerpt":"Docker Stats exporter for Prometheus This exporter uses Apocas's Dockerode library. This exporter was created because the official Docker exporter only exports engine metrics not containers', and the alternative Google's cAdvisor uses quite a lot of resources to run. The output essentially mirrors the CLI output of docker stats . Usage Arguments --port 9487 Exporter listens on this port (default = 9487) --interval 15 Polling interval in seconds (default = 15, minimum 3) --hostip 127.0.0.1 Docker engine IP to connect to (if using HTTP) --hostport 2375 Docker engine port to connect to (if using HTTP) --collectdefault Collect default Prometheus metrics as well (default = false) If no hostip and hostport provided, it defaults to connect via socket to /var/run/docker.sock . Environment Variables The arguments can also be set as env variables instead. Useful if you're using it in a Docker container. 1. DOCKERSTATS PORT 1. DOCKERSTATS INTERVAL 1. DOCKERSTATS HOSTIP 1. DOCKERSTATS HOSTPORT 1. DOCKERSTATS DEFAULTMETRICS Installation From Source Node.js 14 is required to run it. git clone git@github.com:wywywywy/docker stats exporter.git cd docker stats exporter npm ci npm start With Docker docker run -d --restart=always -p 9487:9487 -v /var/run/docker.sock:/var/run/docker.sock wywywywy/docker stats exporter:latest Prometheus Config Add this to prometheus.yml and change the IP/port if needed. - job name: 'docker stats exporter' metrics path: / static configs: - targets: - '127.0.0.1:94","default_branch":null,"files":null,"tree":[],"storefront":"/r/wywywywy","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/wywywywy/docker_stats_exporter/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}