A simple and extensible metrics collection system for InfluxDB.
This project came about because I was wanting to monitor services that don't already have support from tools like Telegraf or Varken.
I also wanted to make something easily extensible, even at runtime. Along with the included modules (which will grow and improve over time), metrx will also dynamically load modules on startup. See Extending for more info.
Copy config.example.yaml
to config.yaml
and edit as needed. Each service needs at least the type
, interval
, and config
keys. The keys under config
will depend on the type of service module being used.
docker run \
--name metrx \
-v /path/to/config/folder:/config \
-v /path/to/custom/modules:/app/modules/custom \ #optional
ghcr.io/reyemxela/metrx:latest
# alternate config mount: -v ./config.yaml:/config/config.yaml
When bind-mounting /app/modules/custom
, metrx will dynamically load any *.py
files found, allowing totally custom modules to be used. See __template.py
in the modules directory for the basic layout needed.
Modules found in custom
also override any built-in modules with the same name.
Docker/Podman: Additionally, if a requirements.txt
file is present in the custom
folder, pip
will attempt to install from it on container startup, so custom modules can use any 3rd-party libraries needed.
Starting out, I'm mainly focusing on including support for services I'm personally running and monitoring, but PRs are more than welcome!