Forge Home

postgres_exporter

Install Postgres Prometheus Exporter

9,346 downloads

609 latest version

3.1 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 1.2.0 (latest)
  • 1.1.0
  • 1.0.2
  • 1.0.1
  • 1.0.0
  • 0.1.2
  • 0.1.1
released Feb 17th 2022
This version is compatible with:
  • Puppet Enterprise 2018.1.x, 2017.3.x, 2017.2.x, 2017.1.x, 2016.5.x, 2016.4.x
  • Puppet >= 4.7.0 < 6.0.0
  • , , ,

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'gbloquel-postgres_exporter', '1.2.0'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add gbloquel-postgres_exporter
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install gbloquel-postgres_exporter --version 1.2.0

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

gbloquel/postgres_exporter — version 1.2.0 Feb 17th 2022

Build Status

postgres_exporter

Table of Contents

  1. Description
  2. Setup - The basics of getting started with postgres_exporter
  3. Usage - Configuration options and additional functionality
  4. Limitations - OS compatibility, etc.
  5. Development - Guide for contributing to the module

Description

Installs the Prometheus Postgres Exporter.

Setup

Beginning with postgres_exporter

To configure a basic default postgres_exporter, declare the postgres_exporter class.

class { 'postgres_exporter':
}

Usage

All parameters for the postgres_exporter module are contained within main postgres_exporter, so for any function of the module set the options you want. See the main usage below for examples.

Install and enable postgres_exporter

include postgres_exporter

Configure the datasource

class { 'postgres_exporter':
  datasource => 'postgresql://postgres:password@localhost:5432/?sslmode=disable',
}

Use the flags

class { 'postgres_exporter':
  flags => {
      'web.listen-address' => ':9999',
      'web.telemetry-path' => '/apis',
  },
}

Add custom queries

class { 'postgres_exporter':
  flags => {
      'extend.query-path' => '/opt/postgres_exporter/query.yaml',
  },
}

You need provided the file query.yaml before. A example of format is available queries.yaml

Others parameters can be used see postgres_exporter

Limitations

Tested on Centos 7, but should be fine on any Linux that uses Systemd.

Development

In the Development section, tell other users the ground rules for contributing to your project and how they should submit their work.