Add node job
This commit is contained in:
parent
58a3771e49
commit
599fafd2aa
|
@ -34,6 +34,33 @@ scrape_configs:
|
||||||
in_cluster: true
|
in_cluster: true
|
||||||
role: apiserver
|
role: apiserver
|
||||||
|
|
||||||
|
- job_name: 'kubernetes-nodes'
|
||||||
|
|
||||||
|
# Default to scraping over https. If required, just disable this or change to
|
||||||
|
# `http`.
|
||||||
|
scheme: https
|
||||||
|
|
||||||
|
# This TLS & bearer token file config is used to connect to the actual scrape
|
||||||
|
# endpoints for cluster components. This is separate to discovery auth
|
||||||
|
# configuration (`in_cluster` below) because discovery & scraping are two
|
||||||
|
# separate concerns in Prometheus.
|
||||||
|
tls_config:
|
||||||
|
ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
|
||||||
|
# If your node certificates are self-signed or use a different CA to the
|
||||||
|
# master CA, then disable certificate verification below. Note that
|
||||||
|
# certificate verification is an integral part of a secure infrastructure
|
||||||
|
# so this should only be disabled in a controlled environment. You can
|
||||||
|
# disable certificate verification by uncommenting the line below.
|
||||||
|
#
|
||||||
|
# insecure_skip_verify: true
|
||||||
|
bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||||
|
|
||||||
|
kubernetes_sd_configs:
|
||||||
|
- api_servers:
|
||||||
|
- 'https://kubernetes.default.svc'
|
||||||
|
in_cluster: true
|
||||||
|
role: node
|
||||||
|
|
||||||
relabel_configs:
|
relabel_configs:
|
||||||
- source_labels: [__meta_kubernetes_role]
|
- source_labels: [__meta_kubernetes_role]
|
||||||
action: keep
|
action: keep
|
||||||
|
|
Loading…
Reference in New Issue