mirror of
https://github.com/carlosedp/cluster-monitoring.git
synced 2024-11-20 19:07:17 +01:00
27 lines
530 B
YAML
27 lines
530 B
YAML
|
apiVersion: monitoring.coreos.com/v1
|
||
|
kind: ServiceMonitor
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: nginx
|
||
|
name: nginx
|
||
|
namespace: monitoring
|
||
|
spec:
|
||
|
endpoints:
|
||
|
- interval: 30s
|
||
|
port: prometheus
|
||
|
relabelings:
|
||
|
- action: replace
|
||
|
regex: (.*)
|
||
|
replacement: $1
|
||
|
sourceLabels:
|
||
|
- __meta_kubernetes_pod_node_name
|
||
|
targetLabel: instance
|
||
|
scheme: http
|
||
|
jobLabel: nginx-exporter
|
||
|
namespaceSelector:
|
||
|
matchNames:
|
||
|
- ingress-nginx
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app.kubernetes.io/name: ingress-nginx
|