Skip to content

Instantly share code, notes, and snippets.

@nakamasato
Last active July 1, 2021 23:00
Show Gist options
  • Save nakamasato/cc31075df190b16f8684ac79ab2c1408 to your computer and use it in GitHub Desktop.
Save nakamasato/cc31075df190b16f8684ac79ab2c1408 to your computer and use it in GitHub Desktop.
Kubernetes HPA with custom metrics (RabbitMQ and Prometheus)
apiVersion: monitoring.coreos.com/v1
kind: PodMonitor
metadata:
namespace: monitoring
name: rabbitmq
spec:
podMetricsEndpoints:
- interval: 15s
port: prometheus
path: /metrics
selector:
matchLabels:
app.kubernetes.io/component: rabbitmq
namespaceSelector:
any: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment