Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/leech001/process_metrics_exporter
Prometheus process metrics exporter
https://github.com/leech001/process_metrics_exporter
docker docker-compose go golang process prometheus prometheus-exporter
Last synced: 25 days ago
JSON representation
Prometheus process metrics exporter
- Host: GitHub
- URL: https://github.com/leech001/process_metrics_exporter
- Owner: leech001
- License: wtfpl
- Created: 2022-06-12T13:25:11.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-01-08T08:04:30.000Z (almost 2 years ago)
- Last Synced: 2024-09-30T11:01:26.425Z (about 1 month ago)
- Topics: docker, docker-compose, go, golang, process, prometheus, prometheus-exporter
- Language: Go
- Homepage:
- Size: 43.9 KB
- Stars: 4
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Prometheus process metrics exporter
![Made](https://img.shields.io/badge/Made%20with-Go-1f425f.svg)![GitHub release version](https://img.shields.io/github/v/release/leech001/process_metrics_exporter?logo=github)![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/leech001/process_metrics_exporter/go_build.yml?label=BUILD%20AND%20RELEASE&logo=github) ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/leech001/process_metrics_exporter/docker-image.yml?label=BUILD%20AND%20PUBLISH%20TO%20DOCKERHUB&logo=github) [![GitHub](https://img.shields.io/badge/Git-Hub-purple.svg)](https://github.com/leech001/process_metrics_exporter) [![Docker](https://img.shields.io/badge/Docker-hub-2496ed.svg)](https://hub.docker.com/r/leech001/process-metrics-exporter) [![License: WTFPL](https://img.shields.io/badge/license-WTFPL-brightgreen)](https://github.com/leech001/process_metrics_exporter/blob/main/LICENSE)## GO (golang) application for counting the number of running processes and forming the corresponding metrics for Prometheus (Alpine Linux images)
The main task is to calculate the number of running processes for a given list of processes, use it to form Gauge metrics and display them on the page with metrics
The application is launched with a command in the 'app' folder
```
go run main -update 5 -port 8080 test1 test2 test3
```where:
- "main" - application name;
- "-update 5" - metrics refresh period on sec;
- "-port 8080" - port where metrics are fed;
- "test1...3" - names of processes.
## Work with Docker (Alpine Linux images)
Download prepared image with application
```
docker pull leech001/process-metrics-exporter
```or start it at once
```
docker run -d -p 8080:8080 leech001/process-metrics-exporter ./procheck -update 5 -port 8080 test1 test2 test3
```metrics are available at
```
http://localhost:8080/metrics
```