Skip to content

Latest commit

 

History

History
96 lines (66 loc) · 2.39 KB

install.md

File metadata and controls

96 lines (66 loc) · 2.39 KB

Installation Guide

Building From Source

prometheus-podman-exporter is using go v1.17 or above.

  1. Clone the repo

  2. Install dependencies

    $ sudo dnf -y install btrfs-progs-devel device-mapper-devel gpgme-devel libassuan-devel
  3. Build and run the executable

    $ make binary
    $ ./bin/prometheus-podman-exporter

Container Image

  • Using unix socket (rootless):

    $ systemctl start --user podman.socket
    $ podman run -e CONTAINER_HOST=unix:///run/podman/podman.sock -v $XDG_RUNTIME_DIR/podman/podman.sock:/run/podman/podman.sock -p 9882:9882 --userns=keep-id:uid=65534 --security-opt label=disable quay.io/navidys/prometheus-podman-exporter
  • Using unix socket (root):

    # systemctl start podman.socket
    # podman run -e CONTAINER_HOST=unix:///run/podman/podman.sock -v /run/podman/podman.sock:/run/podman/podman.sock -u root -p 9882:9882 --security-opt label=disable quay.io/navidys/prometheus-podman-exporter
    
  • Using TCP:

    $ podman system service --time=0 tcp://<ip>:<port>
    $ podman run -e CONTAINER_HOST=tcp://<ip>:<port> --network=host -p 9882:9882 quay.io/navidys/prometheus-podman-exporter:latest

Installing Packaged Versions

AlmaLinux, Rocky Linux

Enable EPEL repository (Rocky Linux >= 9 and AlmaLinux >= 9) and then run:

$ sudo dnf -y install prometheus-podman-exporter

Arch Linux (AUR)

$ yay -S prometheus-podman-exporter

CentOS Stream

Enable EPEL repository (CentOS >= 9) and then run:

$ sudo dnf -y install prometheus-podman-exporter

Fedora

$ sudo dnf -y install prometheus-podman-exporter

RHEL

Enable EPEL repository (RHEL >= 9) and then run:

$ sudo dnf -y install prometheus-podman-exporter

Gentoo

$ sudo emerge app-metrics/prometheus-podman-exporter