Skip to content

huntdatacenter/prometheus-node-exporter-charm

 
 

Repository files navigation

prometheus-node-exporter

Reactive subordinate charm providing prometheus-node-exporter.

Usage

This charm relates to the prometheus charm on the scrape interface, and provides a metrics endpoint for prometheus to scrape on port 9100 by default.

A simple workflow to describe the usage of this charm is as follows:

juju deploy prometheus

juju deploy ubuntu

juju deploy prometheus-node-exporter

juju integrate prometheus-node-exporter ubuntu

juju integrate prometheus-node-exporter:prometheus-target prometheus:target

# juju integrate prometheus-node-exporter:prometheus-manual-job prometheus:manual-jobs

# juju integrate prometheus-node-exporter:scrape prometheus:scrape

Custom node_exporter

pne_version=1.5.0
# Arch: amd64 / arm64
arch="$(dpkg --print-architecture)"
wget "https://github.com/prometheus/node_exporter/releases/download/v${pne_version}/node_exporter-${pne_version}.linux-${arch}.tar.gz" -O ../node_exporter.tar.gz
(cd ..; tar -xzvf "node_exporter.tar.gz" --strip-components=1 "node_exporter-${pne_version}.linux-${arch}/node_exporter" && ls -la node_exporter && rm node_exporter.tar.gz)

Configuration

Charm allows setting host and port to on which prometheus node exporter will listen. Host can be set also to "public" or "private" for charm to set according to unit.

Collectors which are disabled by default can be separately enabled in config (e.g. ntp, systemd, or nfs).

Copyright

License

  • AGPLv3 - see LICENSE

Releases

No releases published

Packages

No packages published

Languages

  • Python 67.7%
  • Makefile 32.3%