README 查看中文版
This project is licensed under the MIT License.
This project is inspired by kube-state-metrics and kubectl.
This project is exposted kubernetes node resource metrics to prometheus. Following Metrics will be exposed.
kube_node_metrics_cpu_request
kube_node_metrics_cpu_limit
kube_node_metrics_mem_request_bytes
kube_node_metrics_mem_limit_bytes
These samples values should be equal to the result of kubectl describe node <node>
.
Available docker images can be fount in docker hub.
Please ensure you have minikube installed.
Run with following commands in your terminal:
minikube start
kubectl apply -f deploy.yaml
kubectl apply -f deploy.yaml
go build .
docker build . -t <image>:<tag>
This exporter also exposed a metric kube_node_metrics_last_full_sync_ok_time_seconds
which indicates the last full sync timestamp in seconds. You can create alert rule to monitor the exporter health with the expression time() - kube_node_metrics_last_full_sync_ok_time_seconds > 300
and you will receive alert if the exporter is not sync sucessfully for 300 seconds.
- support exposed node labels match given pattern