Prometheus-adapter

Exposes custom and external metrics from Prometheus.


What is Prometheus-adapter?

The prometheus-adapter image provides the Prometheus Metrics Adapter for Kubernetes, a component that exposes custom and external metrics from Prometheus to the Kubernetes Custom Metrics API and External Metrics API.

This enables Kubernetes features like Horizontal Pod Autoscaling (HPA) to scale workloads based on Prometheus metrics rather than just built-in metrics like CPU or memory. The adapter acts as a bridge between Prometheus and Kubernetes, translating PromQL queries into metric values that Kubernetes can understand and act upon.

The prometheus-adapter image is essential in environments where autoscaling decisions are driven by business metrics, application-level telemetry, or any custom metric collected in Prometheus.

How to use this image

The prometheus-adapter is deployed as a Kubernetes service and requires a configuration that maps Prometheus metrics to Kubernetes API-compatible names.

Install using Helm (recommended):

<code>helm repo add prometheus-community https://prometheus-community.github.io/helm-chartshelm install prometheus-adapter prometheus-community/prometheus-adapter \  --set prometheus.url=http://prometheus-server</code>

Basic deployment YAML (simplified):

<code>apiVersion: apps/v1kind: Deploymentmetadata:  name: prometheus-adapterspec:  template:    spec:      containers:        - name: prometheus-adapter          image: registry.k8s.io/prometheus-adapter/prometheus-adapter:v0.11.2          args:            - --prometheus-url=http://prometheus.monitoring.svc            - --metrics-relist-interval=1m            - --logtostderr=true</code>

Metrics and access:

  • The adapter exposes the Custom Metrics API and External Metrics API via the Kubernetes aggregator.
  • Prometheus metrics must be explicitly mapped via configuration YAML.

Image variants

The image is published under registry.k8s.io/prometheus-adapter/prometheus-adapter and is versioned by release. There are no Alpine, slim, or OS-based variants.

prometheus-adapter:latest

Latest stable release.Use in dev clusters or testing environments.

prometheus-adapter:<version>

Tagged by semantic version (e.g. v0.11.2, v0.10.0).

Recommended for production to avoid version drift.Configuration is done via a separate YAML file (rules: section), usually provided through Helm or ConfigMap.

Interested in base images that start and stay clean?

This is a not a valid email
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.