prometheus-community / prometheus-community/postgres_exporter

support for kubernetes secrets type in auth_modules for Multi-Target Support (BETA)

Open
#1,063 9 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
3.6k
Forks
835
Avg merge
2d 4h
Merged PRs (30d)
10

Description

I am currently using the Multi-Target Support feature in the postgres_exporter to scrape metrics from multiple Postgres instances deployed in my Kubernetes cluster. The exporter is configured using a scrape job as mentioned in the Muti-Target Support feature docs.

The Muti-Target Support feature currently supports preconfigured auth_modules as way of authenticating to the postgres instances. But the auth_modules only supports the userpass type. I would like to request the support for Kubernetes secrets in the auth_module, allowing users to securely store and manage database credentials in Kubernetes secrets for multiple Postgres instances rather than hardcoding user and password values in the configuration..

Potential Implementation
  • Allow the auth_module to reference a Kubernetes secret by name.
Versions

Postgres Exporter - v0.15.0
Kubernetes - v1.28.4

Thank you for considering this feature request!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Multi-Target Support documentation and the existing auth_modules configuration described there, focusing on how the userpass type is handled. Define the expected Kubernetes secret reference behavior for multiple Postgres instances and verify that the completed feature lets users avoid hardcoding database credentials.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes, postgresql
Domain
authentication, databases, devops
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.