ScrapeConfig
Scope: Namespaced
Version: v1alpha1
ScrapeConfig defines a namespaced Prometheus scrape_config to be aggregated across multiple namespaces into the Prometheus configuration.
- apiVersion
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
- kind
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
- metadata
- spec
Required value
ScrapeConfigSpec is a specification of the desired configuration for a scrape configuration.
- object
Authorization header to use on every scrape request.
- object
Selects a key of a Secret in the namespace that contains the credentials for authentication.
- string
Required value
The key of the secret to select from. Must be a valid secret key.
- string
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- boolean
Specify whether the Secret or its key must be defined
- string
Defines the authentication type. The value is case-insensitive. “Basic” is not a supported value. Default: “Bearer”
- spec.basicAuth
BasicAuth information to use on every scrape request.
- spec.basicAuth.password
The secret in the service monitor namespace that contains the password for authentication.
- spec.basicAuth.password.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.basicAuth.password.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.basicAuth.password.optional
Specify whether the Secret or its key must be defined
- spec.basicAuth.username
The secret in the service monitor namespace that contains the username for authentication.
- spec.basicAuth.username.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.basicAuth.username.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.basicAuth.username.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs
ConsulSDConfigs defines a list of Consul service discovery configurations.
ConsulSDConfig defines a Consul service discovery configuration See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#consul_sd_config
- spec.consulSDConfigs.allow_stale
Allow stale Consul results (see https://www.consul.io/api/features/consistency.html). Will reduce load on Consul. If unset, Prometheus uses its default value.
- object
Authorization header configuration to authenticate against the Consul Server.
- object
Selects a key of a Secret in the namespace that contains the credentials for authentication.
- string
Required value
The key of the secret to select from. Must be a valid secret key.
- string
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- boolean
Specify whether the Secret or its key must be defined
- string
Defines the authentication type. The value is case-insensitive. “Basic” is not a supported value. Default: “Bearer”
- spec.consulSDConfigs.basicAuth
BasicAuth information to authenticate against the Consul Server. More info: https://prometheus.io/docs/operating/configuration/#endpoints
- spec.consulSDConfigs.basicAuth.password
The secret in the service monitor namespace that contains the password for authentication.
- spec.consulSDConfigs.basicAuth.password.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.basicAuth.password.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.basicAuth.password.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.basicAuth.username
The secret in the service monitor namespace that contains the username for authentication.
- spec.consulSDConfigs.basicAuth.username.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.basicAuth.username.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.basicAuth.username.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.datacenter
Consul Datacenter name, if not provided it will use the local Consul Agent Datacenter.
- spec.consulSDConfigs.enable_http2
Whether to enable HTTP2. If unset, Prometheus uses its default value.
- spec.consulSDConfigs.follow_redirects
Configure whether HTTP requests follow HTTP 3xx redirects. If unset, Prometheus uses its default value.
- spec.consulSDConfigs.namespace
Namespaces are only supported in Consul Enterprise.
- spec.consulSDConfigs.no_proxy
Comma-separated string that can contain IPs, CIDR notation, domain names that should be excluded from proxying. IP and domain names can contain port numbers.
- spec.consulSDConfigs.node_meta
Node metadata key/value pairs to filter nodes for a given service.
- spec.consulSDConfigs.oauth2
Optional OAuth 2.0 configuration.
- spec.consulSDConfigs.oauth2.clientId
Required value
The secret or configmap containing the OAuth2 client id
- spec.consulSDConfigs.oauth2.clientId.configMap
ConfigMap containing data to use for the targets.
- spec.consulSDConfigs.oauth2.clientId.configMap.key
Required value
The key to select.
- spec.consulSDConfigs.oauth2.clientId.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.oauth2.clientId.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.consulSDConfigs.oauth2.clientId.secret
Secret containing data to use for the targets.
- spec.consulSDConfigs.oauth2.clientId.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.oauth2.clientId.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.oauth2.clientId.secret.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.oauth2.clientSecret
Required value
The secret containing the OAuth2 client secret
- spec.consulSDConfigs.oauth2.clientSecret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.oauth2.clientSecret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.oauth2.clientSecret.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.oauth2.endpointParams
Parameters to append to the token URL
- spec.consulSDConfigs.oauth2.scopes
OAuth2 scopes used for the token request
- spec.consulSDConfigs.oauth2.tokenUrl
Required value
The URL to fetch the token from
- spec.consulSDConfigs.partition
Admin Partitions are only supported in Consul Enterprise.
- spec.consulSDConfigs.proxy_connect_header
Specifies headers to send to proxies during CONNECT requests.
- spec.consulSDConfigs.proxy_from_environment
Use proxy URL indicated by environment variables (HTTP_PROXY, https_proxy, HTTPs_PROXY, https_proxy, and no_proxy) If unset, Prometheus uses its default value.
- spec.consulSDConfigs.proxy_url
Optional proxy URL.
- spec.consulSDConfigs.refresh_interval
The time after which the provided names are refreshed. On large setup it might be a good idea to increase this value because the catalog will change all the time. If unset, Prometheus uses its default value.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.consulSDConfigs.scheme
HTTP Scheme default “http”
Allowed values:
HTTP
,HTTPS
- spec.consulSDConfigs.server
Required value
A valid string consisting of a hostname or IP followed by an optional port number.
- spec.consulSDConfigs.services
A list of services for which targets are retrieved. If omitted, all services are scraped.
- spec.consulSDConfigs.tag_separator
The string by which Consul tags are joined into the tag label. If unset, Prometheus uses its default value.
- array of strings
An optional list of tags used to filter nodes for a given service. Services must contain all tags in the list.
- spec.consulSDConfigs.tlsConfig
TLS Config
- spec.consulSDConfigs.tlsConfig.ca
Certificate authority used when verifying server certificates.
- spec.consulSDConfigs.tlsConfig.ca.configMap
ConfigMap containing data to use for the targets.
- spec.consulSDConfigs.tlsConfig.ca.configMap.key
Required value
The key to select.
- spec.consulSDConfigs.tlsConfig.ca.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tlsConfig.ca.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.consulSDConfigs.tlsConfig.ca.secret
Secret containing data to use for the targets.
- spec.consulSDConfigs.tlsConfig.ca.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.tlsConfig.ca.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tlsConfig.ca.secret.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.tlsConfig.cert
Client certificate to present when doing client-authentication.
- spec.consulSDConfigs.tlsConfig.cert.configMap
ConfigMap containing data to use for the targets.
- spec.consulSDConfigs.tlsConfig.cert.configMap.key
Required value
The key to select.
- spec.consulSDConfigs.tlsConfig.cert.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tlsConfig.cert.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.consulSDConfigs.tlsConfig.cert.secret
Secret containing data to use for the targets.
- spec.consulSDConfigs.tlsConfig.cert.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.tlsConfig.cert.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tlsConfig.cert.secret.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.tlsConfig.insecureSkipVerify
Disable target certificate validation.
- spec.consulSDConfigs.tlsConfig.keySecret
Secret containing the client key file for the targets.
- spec.consulSDConfigs.tlsConfig.keySecret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.tlsConfig.keySecret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tlsConfig.keySecret.optional
Specify whether the Secret or its key must be defined
- spec.consulSDConfigs.tlsConfig.serverName
Used to verify the hostname for the targets.
- spec.consulSDConfigs.tokenRef
Consul ACL TokenRef, if not provided it will use the ACL from the local Consul Agent.
- spec.consulSDConfigs.tokenRef.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.consulSDConfigs.tokenRef.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.consulSDConfigs.tokenRef.optional
Specify whether the Secret or its key must be defined
- spec.dnsSDConfigs
DNSSDConfigs defines a list of DNS service discovery configurations.
DNSSDConfig allows specifying a set of DNS domain names which are periodically queried to discover a list of targets. The DNS servers to be contacted are read from /etc/resolv.conf. See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#dns_sd_config
- spec.dnsSDConfigs.names
Required value
A list of DNS domain names to be queried.
- spec.dnsSDConfigs.port
The port number used if the query type is not SRV Ignored for SRV records
- spec.dnsSDConfigs.refreshInterval
RefreshInterval configures the time after which the provided names are refreshed. If not set, Prometheus uses its default value.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.dnsSDConfigs.type
The type of DNS query to perform. One of SRV, A, AAAA or MX. If not set, Prometheus uses its default value.
Allowed values:
SRV
,A
,AAAA
,MX
- spec.fileSDConfigs
FileSDConfigs defines a list of file service discovery configurations.
FileSDConfig defines a Prometheus file service discovery configuration See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#file_sd_config
- spec.fileSDConfigs.files
Required value
List of files to be used for file discovery. Recommendation: use absolute paths. While relative paths work, the prometheus-operator project makes no guarantees about the working directory where the configuration file is stored. Files must be mounted using Prometheus.ConfigMaps or Prometheus.Secrets.
- Element of the array
SDFile represents a file used for service discovery
Pattern:
^[^*]*(\*[^/]*)?\.(json|yml|yaml|JSON|YML|YAML)$
- spec.fileSDConfigs.refreshInterval
RefreshInterval configures the refresh interval at which Prometheus will reload the content of the files.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.honorLabels
HonorLabels chooses the metric’s labels on collisions with target labels.
- spec.honorTimestamps
HonorTimestamps controls whether Prometheus respects the timestamps present in scraped data.
- spec.httpSDConfigs
HTTPSDConfigs defines a list of HTTP service discovery configurations.
HTTPSDConfig defines a prometheus HTTP service discovery configuration See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#http_sd_config
- object
Authorization header configuration to authenticate against the target HTTP endpoint.
- object
Selects a key of a Secret in the namespace that contains the credentials for authentication.
- string
Required value
The key of the secret to select from. Must be a valid secret key.
- string
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- boolean
Specify whether the Secret or its key must be defined
- string
Defines the authentication type. The value is case-insensitive. “Basic” is not a supported value. Default: “Bearer”
- spec.httpSDConfigs.basicAuth
BasicAuth information to authenticate against the target HTTP endpoint. More info: https://prometheus.io/docs/operating/configuration/#endpoints
- spec.httpSDConfigs.basicAuth.password
The secret in the service monitor namespace that contains the password for authentication.
- spec.httpSDConfigs.basicAuth.password.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.httpSDConfigs.basicAuth.password.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.basicAuth.password.optional
Specify whether the Secret or its key must be defined
- spec.httpSDConfigs.basicAuth.username
The secret in the service monitor namespace that contains the username for authentication.
- spec.httpSDConfigs.basicAuth.username.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.httpSDConfigs.basicAuth.username.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.basicAuth.username.optional
Specify whether the Secret or its key must be defined
- spec.httpSDConfigs.refreshInterval
RefreshInterval configures the refresh interval at which Prometheus will re-query the endpoint to update the target list.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.httpSDConfigs.tlsConfig
TLS configuration applying to the target HTTP endpoint.
- spec.httpSDConfigs.tlsConfig.ca
Certificate authority used when verifying server certificates.
- spec.httpSDConfigs.tlsConfig.ca.configMap
ConfigMap containing data to use for the targets.
- spec.httpSDConfigs.tlsConfig.ca.configMap.key
Required value
The key to select.
- spec.httpSDConfigs.tlsConfig.ca.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.tlsConfig.ca.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.httpSDConfigs.tlsConfig.ca.secret
Secret containing data to use for the targets.
- spec.httpSDConfigs.tlsConfig.ca.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.httpSDConfigs.tlsConfig.ca.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.tlsConfig.ca.secret.optional
Specify whether the Secret or its key must be defined
- spec.httpSDConfigs.tlsConfig.cert
Client certificate to present when doing client-authentication.
- spec.httpSDConfigs.tlsConfig.cert.configMap
ConfigMap containing data to use for the targets.
- spec.httpSDConfigs.tlsConfig.cert.configMap.key
Required value
The key to select.
- spec.httpSDConfigs.tlsConfig.cert.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.tlsConfig.cert.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.httpSDConfigs.tlsConfig.cert.secret
Secret containing data to use for the targets.
- spec.httpSDConfigs.tlsConfig.cert.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.httpSDConfigs.tlsConfig.cert.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.tlsConfig.cert.secret.optional
Specify whether the Secret or its key must be defined
- spec.httpSDConfigs.tlsConfig.insecureSkipVerify
Disable target certificate validation.
- spec.httpSDConfigs.tlsConfig.keySecret
Secret containing the client key file for the targets.
- spec.httpSDConfigs.tlsConfig.keySecret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.httpSDConfigs.tlsConfig.keySecret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.httpSDConfigs.tlsConfig.keySecret.optional
Specify whether the Secret or its key must be defined
- spec.httpSDConfigs.tlsConfig.serverName
Used to verify the hostname for the targets.
- spec.httpSDConfigs.url
Required value
URL from which the targets are fetched.
Pattern:
^http(s)?://.+$
- spec.keepDroppedTargets
Per-scrape limit on the number of targets dropped by relabeling that will be kept in memory. 0 means no limit. It requires Prometheus >= v2.47.0.
- spec.kubernetesSDConfigs
KubernetesSDConfigs defines a list of Kubernetes service discovery configurations.
KubernetesSDConfig allows retrieving scrape targets from Kubernetes’ REST API. See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#kubernetes_sd_config
- spec.kubernetesSDConfigs.role
Required value
Role of the Kubernetes entities that should be discovered. Currently the only supported role is “Node”.
Allowed values:
Node
- spec.labelLimit
Per-scrape limit on number of labels that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
- spec.labelNameLengthLimit
Per-scrape limit on length of labels name that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
- spec.labelValueLengthLimit
Per-scrape limit on length of labels value that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
- spec.metricRelabelings
MetricRelabelConfigs to apply to samples before ingestion.
RelabelConfig allows dynamic rewriting of the label set for targets, alerts, scraped samples and remote write samples. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config
- spec.metricRelabelings.action
Action to perform based on the regex matching.
Uppercase
andLowercase
actions require Prometheus >= v2.36.0.DropEqual
andKeepEqual
actions require Prometheus >= v2.41.0. Default: “Replace”Default:
"replace"
Allowed values:
replace
,Replace
,keep
,Keep
,drop
,Drop
,hashmod
,HashMod
,labelmap
,LabelMap
,labeldrop
,LabelDrop
,labelkeep
,LabelKeep
,lowercase
,Lowercase
,uppercase
,Uppercase
,keepequal
,KeepEqual
,dropequal
,DropEqual
- spec.metricRelabelings.modulus
Modulus to take of the hash of the source label values. Only applicable when the action is
HashMod
. - spec.metricRelabelings.regex
Regular expression against which the extracted value is matched.
- spec.metricRelabelings.replacement
Replacement value against which a Replace action is performed if the regular expression matches. Regex capture groups are available.
- spec.metricRelabelings.separator
Separator is the string between concatenated SourceLabels.
- spec.metricRelabelings.sourceLabels
The source labels select values from existing labels. Their content is concatenated using the configured Separator and matched against the configured regular expression.
- Element of the array
LabelName is a valid Prometheus label name which may only contain ASCII letters, numbers, as well as underscores.
Pattern:
^[a-zA-Z_][a-zA-Z0-9_]*$
- spec.metricRelabelings.targetLabel
Label to which the resulting string is written in a replacement. It is mandatory for
Replace
,HashMod
,Lowercase
,Uppercase
,KeepEqual
andDropEqual
actions. Regex capture groups are available.
- spec.metricsPath
MetricsPath HTTP path to scrape for metrics. If empty, Prometheus uses the default value (e.g. /metrics).
- spec.params
Optional HTTP URL parameters
- spec.relabelings
RelabelConfigs defines how to rewrite the target’s labels before scraping. Prometheus Operator automatically adds relabelings for a few standard Kubernetes fields. The original scrape job’s name is available via the
__tmp_prometheus_job_name
label. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_configRelabelConfig allows dynamic rewriting of the label set for targets, alerts, scraped samples and remote write samples. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config
- spec.relabelings.action
Action to perform based on the regex matching.
Uppercase
andLowercase
actions require Prometheus >= v2.36.0.DropEqual
andKeepEqual
actions require Prometheus >= v2.41.0. Default: “Replace”Default:
"replace"
Allowed values:
replace
,Replace
,keep
,Keep
,drop
,Drop
,hashmod
,HashMod
,labelmap
,LabelMap
,labeldrop
,LabelDrop
,labelkeep
,LabelKeep
,lowercase
,Lowercase
,uppercase
,Uppercase
,keepequal
,KeepEqual
,dropequal
,DropEqual
- spec.relabelings.modulus
Modulus to take of the hash of the source label values. Only applicable when the action is
HashMod
. - spec.relabelings.regex
Regular expression against which the extracted value is matched.
- spec.relabelings.replacement
Replacement value against which a Replace action is performed if the regular expression matches. Regex capture groups are available.
- spec.relabelings.separator
Separator is the string between concatenated SourceLabels.
- spec.relabelings.sourceLabels
The source labels select values from existing labels. Their content is concatenated using the configured Separator and matched against the configured regular expression.
- Element of the array
LabelName is a valid Prometheus label name which may only contain ASCII letters, numbers, as well as underscores.
Pattern:
^[a-zA-Z_][a-zA-Z0-9_]*$
- spec.relabelings.targetLabel
Label to which the resulting string is written in a replacement. It is mandatory for
Replace
,HashMod
,Lowercase
,Uppercase
,KeepEqual
andDropEqual
actions. Regex capture groups are available.
- spec.sampleLimit
SampleLimit defines per-scrape limit on number of scraped samples that will be accepted.
- spec.scheme
Configures the protocol scheme used for requests. If empty, Prometheus uses HTTP by default.
Allowed values:
HTTP
,HTTPS
- spec.scrapeInterval
ScrapeInterval is the interval between consecutive scrapes.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.scrapeTimeout
ScrapeTimeout is the number of seconds to wait until a scrape request times out.
Pattern:
^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
- spec.staticConfigs
StaticConfigs defines a list of static targets with a common label set.
StaticConfig defines a Prometheus static configuration. See https://prometheus.io/docs/prometheus/latest/configuration/configuration/#scrape_config
- spec.staticConfigs.labels
Labels assigned to all metrics scraped from the targets.
- spec.staticConfigs.targets
List of targets for this static configuration.
- Element of the array
Target represents a target for Prometheus to scrape
- spec.targetLimit
TargetLimit defines a limit on the number of scraped targets that will be accepted.
- spec.tlsConfig
TLS configuration to use on every scrape request
- spec.tlsConfig.ca
Certificate authority used when verifying server certificates.
- spec.tlsConfig.ca.configMap
ConfigMap containing data to use for the targets.
- spec.tlsConfig.ca.configMap.key
Required value
The key to select.
- spec.tlsConfig.ca.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.tlsConfig.ca.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.tlsConfig.ca.secret
Secret containing data to use for the targets.
- spec.tlsConfig.ca.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.tlsConfig.ca.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.tlsConfig.ca.secret.optional
Specify whether the Secret or its key must be defined
- spec.tlsConfig.cert
Client certificate to present when doing client-authentication.
- spec.tlsConfig.cert.configMap
ConfigMap containing data to use for the targets.
- spec.tlsConfig.cert.configMap.key
Required value
The key to select.
- spec.tlsConfig.cert.configMap.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.tlsConfig.cert.configMap.optional
Specify whether the ConfigMap or its key must be defined
- spec.tlsConfig.cert.secret
Secret containing data to use for the targets.
- spec.tlsConfig.cert.secret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.tlsConfig.cert.secret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.tlsConfig.cert.secret.optional
Specify whether the Secret or its key must be defined
- spec.tlsConfig.insecureSkipVerify
Disable target certificate validation.
- spec.tlsConfig.keySecret
Secret containing the client key file for the targets.
- spec.tlsConfig.keySecret.key
Required value
The key of the secret to select from. Must be a valid secret key.
- spec.tlsConfig.keySecret.name
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?
- spec.tlsConfig.keySecret.optional
Specify whether the Secret or its key must be defined
- spec.tlsConfig.serverName
Used to verify the hostname for the targets.