import { ApiObject, ApiObjectMetadata, GroupVersionKind } from 'cdk8s'; import { Construct } from 'constructs'; /** * The `ServiceMonitor` custom resource definition (CRD) defines how `Prometheus` and `PrometheusAgent` can scrape metrics from a group of services. Among other things, it allows to specify: * The services to scrape via label selectors. * The container ports to scrape. * Authentication credentials to use. * Target and metric relabeling. `Prometheus` and `PrometheusAgent` objects select `ServiceMonitor` objects using label and namespace selectors. * * @schema ServiceMonitor */ export declare class ServiceMonitor extends ApiObject { /** * Returns the apiVersion and kind for "ServiceMonitor" */ static readonly GVK: GroupVersionKind; /** * Renders a Kubernetes manifest for "ServiceMonitor". * * This can be used to inline resource manifests inside other objects (e.g. as templates). * * @param props initialization props */ static manifest(props: ServiceMonitorProps): any; /** * Defines a "ServiceMonitor" API object * @param scope the scope in which to define this object * @param id a scope-local name for the object * @param props initialization props */ constructor(scope: Construct, id: string, props: ServiceMonitorProps); /** * Renders the object to Kubernetes JSON. */ toJson(): any; } /** * The `ServiceMonitor` custom resource definition (CRD) defines how `Prometheus` and `PrometheusAgent` can scrape metrics from a group of services. * Among other things, it allows to specify: * * The services to scrape via label selectors. * * The container ports to scrape. * * Authentication credentials to use. * * Target and metric relabeling. * * `Prometheus` and `PrometheusAgent` objects select `ServiceMonitor` objects using label and namespace selectors. * * @schema ServiceMonitor */ export interface ServiceMonitorProps { /** * @schema ServiceMonitor#metadata */ readonly metadata?: ApiObjectMetadata; /** * spec defines the specification of desired Service selection for target discovery by * Prometheus. * * @schema ServiceMonitor#spec */ readonly spec: ServiceMonitorSpec; } /** * Converts an object of type 'ServiceMonitorProps' to JSON representation. */ export declare function toJson_ServiceMonitorProps(obj: ServiceMonitorProps | undefined): Record | undefined; /** * spec defines the specification of desired Service selection for target discovery by * Prometheus. * * @schema ServiceMonitorSpec */ export interface ServiceMonitorSpec { /** * attachMetadata defines additional metadata which is added to the * discovered targets. * * It requires Prometheus >= v2.37.0. * * @schema ServiceMonitorSpec#attachMetadata */ readonly attachMetadata?: ServiceMonitorSpecAttachMetadata; /** * bodySizeLimit when defined, bodySizeLimit specifies a job level limit on the size * of uncompressed response body that will be accepted by Prometheus. * * It requires Prometheus >= v2.28.0. * * @schema ServiceMonitorSpec#bodySizeLimit */ readonly bodySizeLimit?: string; /** * convertClassicHistogramsToNHCB defines whether to convert all scraped classic histograms into a native histogram with custom buckets. * It requires Prometheus >= v3.0.0. * * @schema ServiceMonitorSpec#convertClassicHistogramsToNHCB */ readonly convertClassicHistogramsToNhcb?: boolean; /** * endpoints defines the list of endpoints part of this ServiceMonitor. * Defines how to scrape metrics from Kubernetes [Endpoints](https://kubernetes.io/docs/concepts/services-networking/service/#endpoints) objects. * In most cases, an Endpoints object is backed by a Kubernetes [Service](https://kubernetes.io/docs/concepts/services-networking/service/) object with the same name and labels. * * @schema ServiceMonitorSpec#endpoints */ readonly endpoints: ServiceMonitorSpecEndpoints[]; /** * fallbackScrapeProtocol defines the protocol to use if a scrape returns blank, unparseable, or otherwise invalid Content-Type. * * It requires Prometheus >= v3.0.0. * * @schema ServiceMonitorSpec#fallbackScrapeProtocol */ readonly fallbackScrapeProtocol?: ServiceMonitorSpecFallbackScrapeProtocol; /** * jobLabel selects the label from the associated Kubernetes `Service` * object which will be used as the `job` label for all metrics. * * For example if `jobLabel` is set to `foo` and the Kubernetes `Service` * object is labeled with `foo: bar`, then Prometheus adds the `job="bar"` * label to all ingested metrics. * * If the value of this field is empty or if the label doesn't exist for * the given Service, the `job` label of the metrics defaults to the name * of the associated Kubernetes `Service`. * * @schema ServiceMonitorSpec#jobLabel */ readonly jobLabel?: string; /** * keepDroppedTargets defines the 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. * * @schema ServiceMonitorSpec#keepDroppedTargets */ readonly keepDroppedTargets?: number; /** * labelLimit defines the per-scrape limit on number of labels that will be accepted for a sample. * * It requires Prometheus >= v2.27.0. * * @schema ServiceMonitorSpec#labelLimit */ readonly labelLimit?: number; /** * labelNameLengthLimit defines the per-scrape limit on length of labels name that will be accepted for a sample. * * It requires Prometheus >= v2.27.0. * * @schema ServiceMonitorSpec#labelNameLengthLimit */ readonly labelNameLengthLimit?: number; /** * labelValueLengthLimit defines the per-scrape limit on length of labels value that will be accepted for a sample. * * It requires Prometheus >= v2.27.0. * * @schema ServiceMonitorSpec#labelValueLengthLimit */ readonly labelValueLengthLimit?: number; /** * namespaceSelector defines in which namespace(s) Prometheus should discover the services. * By default, the services are discovered in the same namespace as the `ServiceMonitor` object but it is possible to select pods across different/all namespaces. * * @schema ServiceMonitorSpec#namespaceSelector */ readonly namespaceSelector?: ServiceMonitorSpecNamespaceSelector; /** * nativeHistogramBucketLimit defines ff there are more than this many buckets in a native histogram, * buckets will be merged to stay within the limit. * It requires Prometheus >= v2.45.0. * * @schema ServiceMonitorSpec#nativeHistogramBucketLimit */ readonly nativeHistogramBucketLimit?: number; /** * nativeHistogramMinBucketFactor defines if the growth factor of one bucket to the next is smaller than this, * buckets will be merged to increase the factor sufficiently. * It requires Prometheus >= v2.50.0. * * @schema ServiceMonitorSpec#nativeHistogramMinBucketFactor */ readonly nativeHistogramMinBucketFactor?: ServiceMonitorSpecNativeHistogramMinBucketFactor; /** * podTargetLabels defines the labels which are transferred from the * associated Kubernetes `Pod` object onto the ingested metrics. * * @schema ServiceMonitorSpec#podTargetLabels */ readonly podTargetLabels?: string[]; /** * sampleLimit defines a per-scrape limit on the number of scraped samples * that will be accepted. * * @schema ServiceMonitorSpec#sampleLimit */ readonly sampleLimit?: number; /** * scrapeClass defines the scrape class to apply. * * @schema ServiceMonitorSpec#scrapeClass */ readonly scrapeClass?: string; /** * scrapeClassicHistograms defines whether to scrape a classic histogram that is also exposed as a native histogram. * It requires Prometheus >= v2.45.0. * * Notice: `scrapeClassicHistograms` corresponds to the `always_scrape_classic_histograms` field in the Prometheus configuration. * * @schema ServiceMonitorSpec#scrapeClassicHistograms */ readonly scrapeClassicHistograms?: boolean; /** * scrapeProtocols defines the protocols to negotiate during a scrape. It tells clients the * protocols supported by Prometheus in order of preference (from most to least preferred). * * If unset, Prometheus uses its default value. * * It requires Prometheus >= v2.49.0. * * @schema ServiceMonitorSpec#scrapeProtocols */ readonly scrapeProtocols?: ServiceMonitorSpecScrapeProtocols[]; /** * selector defines the label selector to select the Kubernetes `Endpoints` objects to scrape metrics from. * * @schema ServiceMonitorSpec#selector */ readonly selector: ServiceMonitorSpecSelector; /** * selectorMechanism defines the mechanism used to select the endpoints to scrape. * By default, the selection process relies on relabel configurations to filter the discovered targets. * Alternatively, you can opt in for role selectors, which may offer better efficiency in large clusters. * Which strategy is best for your use case needs to be carefully evaluated. * * It requires Prometheus >= v2.17.0. * * @schema ServiceMonitorSpec#selectorMechanism */ readonly selectorMechanism?: ServiceMonitorSpecSelectorMechanism; /** * serviceDiscoveryRole defines the service discovery role used to discover targets. * * If set, the value should be either "Endpoints" or "EndpointSlice". * Otherwise it defaults to the value defined in the * Prometheus/PrometheusAgent resource. * * @schema ServiceMonitorSpec#serviceDiscoveryRole */ readonly serviceDiscoveryRole?: ServiceMonitorSpecServiceDiscoveryRole; /** * targetLabels defines the labels which are transferred from the * associated Kubernetes `Service` object onto the ingested metrics. * * @schema ServiceMonitorSpec#targetLabels */ readonly targetLabels?: string[]; /** * targetLimit defines a limit on the number of scraped targets that will * be accepted. * * @schema ServiceMonitorSpec#targetLimit */ readonly targetLimit?: number; } /** * Converts an object of type 'ServiceMonitorSpec' to JSON representation. */ export declare function toJson_ServiceMonitorSpec(obj: ServiceMonitorSpec | undefined): Record | undefined; /** * attachMetadata defines additional metadata which is added to the * discovered targets. * * It requires Prometheus >= v2.37.0. * * @schema ServiceMonitorSpecAttachMetadata */ export interface ServiceMonitorSpecAttachMetadata { /** * node when set to true, Prometheus attaches node metadata to the discovered * targets. * * The Prometheus service account must have the `list` and `watch` * permissions on the `Nodes` objects. * * @schema ServiceMonitorSpecAttachMetadata#node */ readonly node?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecAttachMetadata' to JSON representation. */ export declare function toJson_ServiceMonitorSpecAttachMetadata(obj: ServiceMonitorSpecAttachMetadata | undefined): Record | undefined; /** * Endpoint defines an endpoint serving Prometheus metrics to be scraped by * Prometheus. * * @schema ServiceMonitorSpecEndpoints */ export interface ServiceMonitorSpecEndpoints { /** * authorization configures the Authorization header credentials to use when * scraping the target. * * Cannot be set at the same time as `basicAuth`, or `oauth2`. * * @schema ServiceMonitorSpecEndpoints#authorization */ readonly authorization?: ServiceMonitorSpecEndpointsAuthorization; /** * basicAuth defines the Basic Authentication credentials to use when * scraping the target. * * Cannot be set at the same time as `authorization`, or `oauth2`. * * @schema ServiceMonitorSpecEndpoints#basicAuth */ readonly basicAuth?: ServiceMonitorSpecEndpointsBasicAuth; /** * bearerTokenFile defines the file to read bearer token for scraping the target. * * Deprecated: use `authorization` instead. * * @schema ServiceMonitorSpecEndpoints#bearerTokenFile */ readonly bearerTokenFile?: string; /** * bearerTokenSecret defines a key of a Secret containing the bearer * token for scraping targets. The secret needs to be in the same namespace * as the ServiceMonitor object and readable by the Prometheus Operator. * * Deprecated: use `authorization` instead. * * @schema ServiceMonitorSpecEndpoints#bearerTokenSecret */ readonly bearerTokenSecret?: ServiceMonitorSpecEndpointsBearerTokenSecret; /** * enableHttp2 can be used to disable HTTP2 when scraping the target. * * @schema ServiceMonitorSpecEndpoints#enableHttp2 */ readonly enableHttp2?: boolean; /** * filterRunning when true, the pods which are not running (e.g. either in Failed or * Succeeded state) are dropped during the target discovery. * * If unset, the filtering is enabled. * * More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-phase * * @schema ServiceMonitorSpecEndpoints#filterRunning */ readonly filterRunning?: boolean; /** * followRedirects defines whether the scrape requests should follow HTTP * 3xx redirects. * * @schema ServiceMonitorSpecEndpoints#followRedirects */ readonly followRedirects?: boolean; /** * honorLabels defines when true the metric's labels when they collide * with the target's labels. * * @schema ServiceMonitorSpecEndpoints#honorLabels */ readonly honorLabels?: boolean; /** * honorTimestamps defines whether Prometheus preserves the timestamps * when exposed by the target. * * @schema ServiceMonitorSpecEndpoints#honorTimestamps */ readonly honorTimestamps?: boolean; /** * interval at which Prometheus scrapes the metrics from the target. * * If empty, Prometheus uses the global scrape interval. * * @schema ServiceMonitorSpecEndpoints#interval */ readonly interval?: string; /** * metricRelabelings defines the relabeling rules to apply to the * samples before ingestion. * * @schema ServiceMonitorSpecEndpoints#metricRelabelings */ readonly metricRelabelings?: ServiceMonitorSpecEndpointsMetricRelabelings[]; /** * noProxy defines a 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. * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpoints#noProxy */ readonly noProxy?: string; /** * oauth2 defines the OAuth2 settings to use when scraping the target. * * It requires Prometheus >= 2.27.0. * * Cannot be set at the same time as `authorization`, or `basicAuth`. * * @schema ServiceMonitorSpecEndpoints#oauth2 */ readonly oauth2?: ServiceMonitorSpecEndpointsOauth2; /** * params define optional HTTP URL parameters. * * @schema ServiceMonitorSpecEndpoints#params */ readonly params?: { [key: string]: string[]; }; /** * path defines the HTTP path from which to scrape for metrics. * * If empty, Prometheus uses the default value (e.g. `/metrics`). * * @schema ServiceMonitorSpecEndpoints#path */ readonly path?: string; /** * port defines the name of the Service port which this endpoint refers to. * * It takes precedence over `targetPort`. * * @schema ServiceMonitorSpecEndpoints#port */ readonly port?: string; /** * proxyConnectHeader optionally specifies headers to send to * proxies during CONNECT requests. * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpoints#proxyConnectHeader */ readonly proxyConnectHeader?: { [key: string]: ServiceMonitorSpecEndpointsProxyConnectHeader[]; }; /** * proxyFromEnvironment defines whether to use the proxy configuration defined by environment variables (HTTP_PROXY, HTTPS_PROXY, and NO_PROXY). * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpoints#proxyFromEnvironment */ readonly proxyFromEnvironment?: boolean; /** * proxyUrl defines the HTTP proxy server to use. * * @schema ServiceMonitorSpecEndpoints#proxyUrl */ readonly proxyUrl?: string; /** * relabelings defines the relabeling rules to apply the target's * metadata labels. * * The 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_config * * @schema ServiceMonitorSpecEndpoints#relabelings */ readonly relabelings?: ServiceMonitorSpecEndpointsRelabelings[]; /** * scheme defines the HTTP scheme to use when scraping the metrics. * * @schema ServiceMonitorSpecEndpoints#scheme */ readonly scheme?: ServiceMonitorSpecEndpointsScheme; /** * scrapeTimeout defines the timeout after which Prometheus considers the scrape to be failed. * * If empty, Prometheus uses the global scrape timeout unless it is less * than the target's scrape interval value in which the latter is used. * The value cannot be greater than the scrape interval otherwise the operator will reject the resource. * * @schema ServiceMonitorSpecEndpoints#scrapeTimeout */ readonly scrapeTimeout?: string; /** * targetPort defines the name or number of the target port of the `Pod` object behind the * Service. The port must be specified with the container's port property. * * @schema ServiceMonitorSpecEndpoints#targetPort */ readonly targetPort?: ServiceMonitorSpecEndpointsTargetPort; /** * tlsConfig defines the TLS configuration to use when scraping the target. * * @schema ServiceMonitorSpecEndpoints#tlsConfig */ readonly tlsConfig?: ServiceMonitorSpecEndpointsTlsConfig; /** * trackTimestampsStaleness defines whether Prometheus tracks staleness of * the metrics that have an explicit timestamp present in scraped data. * Has no effect if `honorTimestamps` is false. * * It requires Prometheus >= v2.48.0. * * @schema ServiceMonitorSpecEndpoints#trackTimestampsStaleness */ readonly trackTimestampsStaleness?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpoints' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpoints(obj: ServiceMonitorSpecEndpoints | undefined): Record | undefined; /** * fallbackScrapeProtocol defines the protocol to use if a scrape returns blank, unparseable, or otherwise invalid Content-Type. * * It requires Prometheus >= v3.0.0. * * @schema ServiceMonitorSpecFallbackScrapeProtocol */ export declare enum ServiceMonitorSpecFallbackScrapeProtocol { /** PrometheusProto */ PROMETHEUS_PROTO = "PrometheusProto", /** OpenMetricsText0.0.1 */ OPEN_METRICS_TEXT0_0_1 = "OpenMetricsText0.0.1", /** OpenMetricsText1.0.0 */ OPEN_METRICS_TEXT1_0_0 = "OpenMetricsText1.0.0", /** PrometheusText0.0.4 */ PROMETHEUS_TEXT0_0_4 = "PrometheusText0.0.4", /** PrometheusText1.0.0 */ PROMETHEUS_TEXT1_0_0 = "PrometheusText1.0.0" } /** * namespaceSelector defines in which namespace(s) Prometheus should discover the services. * By default, the services are discovered in the same namespace as the `ServiceMonitor` object but it is possible to select pods across different/all namespaces. * * @schema ServiceMonitorSpecNamespaceSelector */ export interface ServiceMonitorSpecNamespaceSelector { /** * any defines the boolean describing whether all namespaces are selected in contrast to a * list restricting them. * * @schema ServiceMonitorSpecNamespaceSelector#any */ readonly any?: boolean; /** * matchNames defines the list of namespace names to select from. * * @schema ServiceMonitorSpecNamespaceSelector#matchNames */ readonly matchNames?: string[]; } /** * Converts an object of type 'ServiceMonitorSpecNamespaceSelector' to JSON representation. */ export declare function toJson_ServiceMonitorSpecNamespaceSelector(obj: ServiceMonitorSpecNamespaceSelector | undefined): Record | undefined; /** * nativeHistogramMinBucketFactor defines if the growth factor of one bucket to the next is smaller than this, * buckets will be merged to increase the factor sufficiently. * It requires Prometheus >= v2.50.0. * * @schema ServiceMonitorSpecNativeHistogramMinBucketFactor */ export declare class ServiceMonitorSpecNativeHistogramMinBucketFactor { readonly value: number | string; static fromNumber(value: number): ServiceMonitorSpecNativeHistogramMinBucketFactor; static fromString(value: string): ServiceMonitorSpecNativeHistogramMinBucketFactor; private constructor(); } /** * ScrapeProtocol represents a protocol used by Prometheus for scraping metrics. * Supported values are: * * `OpenMetricsText0.0.1` * * `OpenMetricsText1.0.0` * * `PrometheusProto` * * `PrometheusText0.0.4` * * `PrometheusText1.0.0` * * @schema ServiceMonitorSpecScrapeProtocols */ export declare enum ServiceMonitorSpecScrapeProtocols { /** PrometheusProto */ PROMETHEUS_PROTO = "PrometheusProto", /** OpenMetricsText0.0.1 */ OPEN_METRICS_TEXT0_0_1 = "OpenMetricsText0.0.1", /** OpenMetricsText1.0.0 */ OPEN_METRICS_TEXT1_0_0 = "OpenMetricsText1.0.0", /** PrometheusText0.0.4 */ PROMETHEUS_TEXT0_0_4 = "PrometheusText0.0.4", /** PrometheusText1.0.0 */ PROMETHEUS_TEXT1_0_0 = "PrometheusText1.0.0" } /** * selector defines the label selector to select the Kubernetes `Endpoints` objects to scrape metrics from. * * @schema ServiceMonitorSpecSelector */ export interface ServiceMonitorSpecSelector { /** * matchExpressions is a list of label selector requirements. The requirements are ANDed. * * @schema ServiceMonitorSpecSelector#matchExpressions */ readonly matchExpressions?: ServiceMonitorSpecSelectorMatchExpressions[]; /** * matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels * map is equivalent to an element of matchExpressions, whose key field is "key", the * operator is "In", and the values array contains only "value". The requirements are ANDed. * * @schema ServiceMonitorSpecSelector#matchLabels */ readonly matchLabels?: { [key: string]: string; }; } /** * Converts an object of type 'ServiceMonitorSpecSelector' to JSON representation. */ export declare function toJson_ServiceMonitorSpecSelector(obj: ServiceMonitorSpecSelector | undefined): Record | undefined; /** * selectorMechanism defines the mechanism used to select the endpoints to scrape. * By default, the selection process relies on relabel configurations to filter the discovered targets. * Alternatively, you can opt in for role selectors, which may offer better efficiency in large clusters. * Which strategy is best for your use case needs to be carefully evaluated. * * It requires Prometheus >= v2.17.0. * * @schema ServiceMonitorSpecSelectorMechanism */ export declare enum ServiceMonitorSpecSelectorMechanism { /** RelabelConfig */ RELABEL_CONFIG = "RelabelConfig", /** RoleSelector */ ROLE_SELECTOR = "RoleSelector" } /** * serviceDiscoveryRole defines the service discovery role used to discover targets. * * If set, the value should be either "Endpoints" or "EndpointSlice". * Otherwise it defaults to the value defined in the * Prometheus/PrometheusAgent resource. * * @schema ServiceMonitorSpecServiceDiscoveryRole */ export declare enum ServiceMonitorSpecServiceDiscoveryRole { /** Endpoints */ ENDPOINTS = "Endpoints", /** EndpointSlice */ ENDPOINT_SLICE = "EndpointSlice" } /** * authorization configures the Authorization header credentials to use when * scraping the target. * * Cannot be set at the same time as `basicAuth`, or `oauth2`. * * @schema ServiceMonitorSpecEndpointsAuthorization */ export interface ServiceMonitorSpecEndpointsAuthorization { /** * credentials defines a key of a Secret in the namespace that contains the credentials for authentication. * * @schema ServiceMonitorSpecEndpointsAuthorization#credentials */ readonly credentials?: ServiceMonitorSpecEndpointsAuthorizationCredentials; /** * type defines the authentication type. The value is case-insensitive. * * "Basic" is not a supported value. * * Default: "Bearer" * * @schema ServiceMonitorSpecEndpointsAuthorization#type */ readonly type?: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsAuthorization' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsAuthorization(obj: ServiceMonitorSpecEndpointsAuthorization | undefined): Record | undefined; /** * basicAuth defines the Basic Authentication credentials to use when * scraping the target. * * Cannot be set at the same time as `authorization`, or `oauth2`. * * @schema ServiceMonitorSpecEndpointsBasicAuth */ export interface ServiceMonitorSpecEndpointsBasicAuth { /** * password defines a key of a Secret containing the password for * authentication. * * @schema ServiceMonitorSpecEndpointsBasicAuth#password */ readonly password?: ServiceMonitorSpecEndpointsBasicAuthPassword; /** * username defines a key of a Secret containing the username for * authentication. * * @schema ServiceMonitorSpecEndpointsBasicAuth#username */ readonly username?: ServiceMonitorSpecEndpointsBasicAuthUsername; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsBasicAuth' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsBasicAuth(obj: ServiceMonitorSpecEndpointsBasicAuth | undefined): Record | undefined; /** * bearerTokenSecret defines a key of a Secret containing the bearer * token for scraping targets. The secret needs to be in the same namespace * as the ServiceMonitor object and readable by the Prometheus Operator. * * Deprecated: use `authorization` instead. * * @schema ServiceMonitorSpecEndpointsBearerTokenSecret */ export interface ServiceMonitorSpecEndpointsBearerTokenSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsBearerTokenSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsBearerTokenSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsBearerTokenSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsBearerTokenSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsBearerTokenSecret(obj: ServiceMonitorSpecEndpointsBearerTokenSecret | undefined): Record | undefined; /** * 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 * * @schema ServiceMonitorSpecEndpointsMetricRelabelings */ export interface ServiceMonitorSpecEndpointsMetricRelabelings { /** * action to perform based on the regex matching. * * `Uppercase` and `Lowercase` actions require Prometheus >= v2.36.0. * `DropEqual` and `KeepEqual` actions require Prometheus >= v2.41.0. * * Default: "Replace" * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#action */ readonly action?: ServiceMonitorSpecEndpointsMetricRelabelingsAction; /** * modulus to take of the hash of the source label values. * * Only applicable when the action is `HashMod`. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#modulus */ readonly modulus?: number; /** * regex defines the regular expression against which the extracted value is matched. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#regex */ readonly regex?: string; /** * replacement value against which a Replace action is performed if the * regular expression matches. * * Regex capture groups are available. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#replacement */ readonly replacement?: string; /** * separator defines the string between concatenated SourceLabels. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#separator */ readonly separator?: string; /** * sourceLabels defines the source labels select values from existing labels. Their content is * concatenated using the configured Separator and matched against the * configured regular expression. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#sourceLabels */ readonly sourceLabels?: string[]; /** * targetLabel defines the label to which the resulting string is written in a replacement. * * It is mandatory for `Replace`, `HashMod`, `Lowercase`, `Uppercase`, * `KeepEqual` and `DropEqual` actions. * * Regex capture groups are available. * * @schema ServiceMonitorSpecEndpointsMetricRelabelings#targetLabel */ readonly targetLabel?: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsMetricRelabelings' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsMetricRelabelings(obj: ServiceMonitorSpecEndpointsMetricRelabelings | undefined): Record | undefined; /** * oauth2 defines the OAuth2 settings to use when scraping the target. * * It requires Prometheus >= 2.27.0. * * Cannot be set at the same time as `authorization`, or `basicAuth`. * * @schema ServiceMonitorSpecEndpointsOauth2 */ export interface ServiceMonitorSpecEndpointsOauth2 { /** * clientId defines a key of a Secret or ConfigMap containing the * OAuth2 client's ID. * * @schema ServiceMonitorSpecEndpointsOauth2#clientId */ readonly clientId: ServiceMonitorSpecEndpointsOauth2ClientId; /** * clientSecret defines a key of a Secret containing the OAuth2 * client's secret. * * @schema ServiceMonitorSpecEndpointsOauth2#clientSecret */ readonly clientSecret: ServiceMonitorSpecEndpointsOauth2ClientSecret; /** * endpointParams configures the HTTP parameters to append to the token * URL. * * @schema ServiceMonitorSpecEndpointsOauth2#endpointParams */ readonly endpointParams?: { [key: string]: string; }; /** * noProxy defines a 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. * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpointsOauth2#noProxy */ readonly noProxy?: string; /** * proxyConnectHeader optionally specifies headers to send to * proxies during CONNECT requests. * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpointsOauth2#proxyConnectHeader */ readonly proxyConnectHeader?: { [key: string]: ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader[]; }; /** * proxyFromEnvironment defines whether to use the proxy configuration defined by environment variables (HTTP_PROXY, HTTPS_PROXY, and NO_PROXY). * * It requires Prometheus >= v2.43.0, Alertmanager >= v0.25.0 or Thanos >= v0.32.0. * * @schema ServiceMonitorSpecEndpointsOauth2#proxyFromEnvironment */ readonly proxyFromEnvironment?: boolean; /** * proxyUrl defines the HTTP proxy server to use. * * @schema ServiceMonitorSpecEndpointsOauth2#proxyUrl */ readonly proxyUrl?: string; /** * scopes defines the OAuth2 scopes used for the token request. * * @schema ServiceMonitorSpecEndpointsOauth2#scopes */ readonly scopes?: string[]; /** * tlsConfig defines the TLS configuration to use when connecting to the OAuth2 server. * It requires Prometheus >= v2.43.0. * * @schema ServiceMonitorSpecEndpointsOauth2#tlsConfig */ readonly tlsConfig?: ServiceMonitorSpecEndpointsOauth2TlsConfig; /** * tokenUrl defines the URL to fetch the token from. * * @schema ServiceMonitorSpecEndpointsOauth2#tokenUrl */ readonly tokenUrl: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2(obj: ServiceMonitorSpecEndpointsOauth2 | undefined): Record | undefined; /** * SecretKeySelector selects a key of a Secret. * * @schema ServiceMonitorSpecEndpointsProxyConnectHeader */ export interface ServiceMonitorSpecEndpointsProxyConnectHeader { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsProxyConnectHeader#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsProxyConnectHeader#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsProxyConnectHeader#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsProxyConnectHeader' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsProxyConnectHeader(obj: ServiceMonitorSpecEndpointsProxyConnectHeader | undefined): Record | undefined; /** * 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 * * @schema ServiceMonitorSpecEndpointsRelabelings */ export interface ServiceMonitorSpecEndpointsRelabelings { /** * action to perform based on the regex matching. * * `Uppercase` and `Lowercase` actions require Prometheus >= v2.36.0. * `DropEqual` and `KeepEqual` actions require Prometheus >= v2.41.0. * * Default: "Replace" * * @schema ServiceMonitorSpecEndpointsRelabelings#action */ readonly action?: ServiceMonitorSpecEndpointsRelabelingsAction; /** * modulus to take of the hash of the source label values. * * Only applicable when the action is `HashMod`. * * @schema ServiceMonitorSpecEndpointsRelabelings#modulus */ readonly modulus?: number; /** * regex defines the regular expression against which the extracted value is matched. * * @schema ServiceMonitorSpecEndpointsRelabelings#regex */ readonly regex?: string; /** * replacement value against which a Replace action is performed if the * regular expression matches. * * Regex capture groups are available. * * @schema ServiceMonitorSpecEndpointsRelabelings#replacement */ readonly replacement?: string; /** * separator defines the string between concatenated SourceLabels. * * @schema ServiceMonitorSpecEndpointsRelabelings#separator */ readonly separator?: string; /** * sourceLabels defines the source labels select values from existing labels. Their content is * concatenated using the configured Separator and matched against the * configured regular expression. * * @schema ServiceMonitorSpecEndpointsRelabelings#sourceLabels */ readonly sourceLabels?: string[]; /** * targetLabel defines the label to which the resulting string is written in a replacement. * * It is mandatory for `Replace`, `HashMod`, `Lowercase`, `Uppercase`, * `KeepEqual` and `DropEqual` actions. * * Regex capture groups are available. * * @schema ServiceMonitorSpecEndpointsRelabelings#targetLabel */ readonly targetLabel?: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsRelabelings' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsRelabelings(obj: ServiceMonitorSpecEndpointsRelabelings | undefined): Record | undefined; /** * scheme defines the HTTP scheme to use when scraping the metrics. * * @schema ServiceMonitorSpecEndpointsScheme */ export declare enum ServiceMonitorSpecEndpointsScheme { /** http */ HTTP = "http", /** https */ HTTPS = "https" } /** * targetPort defines the name or number of the target port of the `Pod` object behind the * Service. The port must be specified with the container's port property. * * @schema ServiceMonitorSpecEndpointsTargetPort */ export declare class ServiceMonitorSpecEndpointsTargetPort { readonly value: number | string; static fromNumber(value: number): ServiceMonitorSpecEndpointsTargetPort; static fromString(value: string): ServiceMonitorSpecEndpointsTargetPort; private constructor(); } /** * tlsConfig defines the TLS configuration to use when scraping the target. * * @schema ServiceMonitorSpecEndpointsTlsConfig */ export interface ServiceMonitorSpecEndpointsTlsConfig { /** * ca defines the Certificate authority used when verifying server certificates. * * @schema ServiceMonitorSpecEndpointsTlsConfig#ca */ readonly ca?: ServiceMonitorSpecEndpointsTlsConfigCa; /** * caFile defines the path to the CA cert in the Prometheus container to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfig#caFile */ readonly caFile?: string; /** * cert defines the Client certificate to present when doing client-authentication. * * @schema ServiceMonitorSpecEndpointsTlsConfig#cert */ readonly cert?: ServiceMonitorSpecEndpointsTlsConfigCert; /** * certFile defines the path to the client cert file in the Prometheus container for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfig#certFile */ readonly certFile?: string; /** * insecureSkipVerify defines how to disable target certificate validation. * * @schema ServiceMonitorSpecEndpointsTlsConfig#insecureSkipVerify */ readonly insecureSkipVerify?: boolean; /** * keyFile defines the path to the client key file in the Prometheus container for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfig#keyFile */ readonly keyFile?: string; /** * keySecret defines the Secret containing the client key file for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfig#keySecret */ readonly keySecret?: ServiceMonitorSpecEndpointsTlsConfigKeySecret; /** * maxVersion defines the maximum acceptable TLS version. * * It requires Prometheus >= v2.41.0 or Thanos >= v0.31.0. * * @schema ServiceMonitorSpecEndpointsTlsConfig#maxVersion */ readonly maxVersion?: ServiceMonitorSpecEndpointsTlsConfigMaxVersion; /** * minVersion defines the minimum acceptable TLS version. * * It requires Prometheus >= v2.35.0 or Thanos >= v0.28.0. * * @schema ServiceMonitorSpecEndpointsTlsConfig#minVersion */ readonly minVersion?: ServiceMonitorSpecEndpointsTlsConfigMinVersion; /** * serverName is used to verify the hostname for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfig#serverName */ readonly serverName?: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfig' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfig(obj: ServiceMonitorSpecEndpointsTlsConfig | undefined): Record | undefined; /** * A label selector requirement is a selector that contains values, a key, and an operator that * relates the key and values. * * @schema ServiceMonitorSpecSelectorMatchExpressions */ export interface ServiceMonitorSpecSelectorMatchExpressions { /** * key is the label key that the selector applies to. * * @schema ServiceMonitorSpecSelectorMatchExpressions#key */ readonly key: string; /** * operator represents a key's relationship to a set of values. * Valid operators are In, NotIn, Exists and DoesNotExist. * * @schema ServiceMonitorSpecSelectorMatchExpressions#operator */ readonly operator: string; /** * values is an array of string values. If the operator is In or NotIn, * the values array must be non-empty. If the operator is Exists or DoesNotExist, * the values array must be empty. This array is replaced during a strategic * merge patch. * * @schema ServiceMonitorSpecSelectorMatchExpressions#values */ readonly values?: string[]; } /** * Converts an object of type 'ServiceMonitorSpecSelectorMatchExpressions' to JSON representation. */ export declare function toJson_ServiceMonitorSpecSelectorMatchExpressions(obj: ServiceMonitorSpecSelectorMatchExpressions | undefined): Record | undefined; /** * credentials defines a key of a Secret in the namespace that contains the credentials for authentication. * * @schema ServiceMonitorSpecEndpointsAuthorizationCredentials */ export interface ServiceMonitorSpecEndpointsAuthorizationCredentials { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsAuthorizationCredentials#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsAuthorizationCredentials#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsAuthorizationCredentials#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsAuthorizationCredentials' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsAuthorizationCredentials(obj: ServiceMonitorSpecEndpointsAuthorizationCredentials | undefined): Record | undefined; /** * password defines a key of a Secret containing the password for * authentication. * * @schema ServiceMonitorSpecEndpointsBasicAuthPassword */ export interface ServiceMonitorSpecEndpointsBasicAuthPassword { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsBasicAuthPassword#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsBasicAuthPassword#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsBasicAuthPassword#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsBasicAuthPassword' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsBasicAuthPassword(obj: ServiceMonitorSpecEndpointsBasicAuthPassword | undefined): Record | undefined; /** * username defines a key of a Secret containing the username for * authentication. * * @schema ServiceMonitorSpecEndpointsBasicAuthUsername */ export interface ServiceMonitorSpecEndpointsBasicAuthUsername { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsBasicAuthUsername#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsBasicAuthUsername#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsBasicAuthUsername#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsBasicAuthUsername' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsBasicAuthUsername(obj: ServiceMonitorSpecEndpointsBasicAuthUsername | undefined): Record | undefined; /** * action to perform based on the regex matching. * * `Uppercase` and `Lowercase` actions require Prometheus >= v2.36.0. * `DropEqual` and `KeepEqual` actions require Prometheus >= v2.41.0. * * Default: "Replace" * * @schema ServiceMonitorSpecEndpointsMetricRelabelingsAction */ export declare enum ServiceMonitorSpecEndpointsMetricRelabelingsAction { /** replace */ REPLACE = "replace", /** keep */ KEEP = "keep", /** drop */ DROP = "drop", /** hashmod */ HASHMOD = "hashmod", /** labelmap */ LABELMAP = "labelmap", /** labeldrop */ LABELDROP = "labeldrop", /** labelkeep */ LABELKEEP = "labelkeep", /** lowercase */ LOWERCASE = "lowercase", /** uppercase */ UPPERCASE = "uppercase", /** keepequal */ KEEPEQUAL = "keepequal", /** dropequal */ DROPEQUAL = "dropequal" } /** * clientId defines a key of a Secret or ConfigMap containing the * OAuth2 client's ID. * * @schema ServiceMonitorSpecEndpointsOauth2ClientId */ export interface ServiceMonitorSpecEndpointsOauth2ClientId { /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2ClientId#configMap */ readonly configMap?: ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2ClientId#secret */ readonly secret?: ServiceMonitorSpecEndpointsOauth2ClientIdSecret; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2ClientId' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2ClientId(obj: ServiceMonitorSpecEndpointsOauth2ClientId | undefined): Record | undefined; /** * clientSecret defines a key of a Secret containing the OAuth2 * client's secret. * * @schema ServiceMonitorSpecEndpointsOauth2ClientSecret */ export interface ServiceMonitorSpecEndpointsOauth2ClientSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2ClientSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2ClientSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2ClientSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2ClientSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2ClientSecret(obj: ServiceMonitorSpecEndpointsOauth2ClientSecret | undefined): Record | undefined; /** * SecretKeySelector selects a key of a Secret. * * @schema ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader */ export interface ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader(obj: ServiceMonitorSpecEndpointsOauth2ProxyConnectHeader | undefined): Record | undefined; /** * tlsConfig defines the TLS configuration to use when connecting to the OAuth2 server. * It requires Prometheus >= v2.43.0. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfig { /** * ca defines the Certificate authority used when verifying server certificates. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#ca */ readonly ca?: ServiceMonitorSpecEndpointsOauth2TlsConfigCa; /** * cert defines the Client certificate to present when doing client-authentication. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#cert */ readonly cert?: ServiceMonitorSpecEndpointsOauth2TlsConfigCert; /** * insecureSkipVerify defines how to disable target certificate validation. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#insecureSkipVerify */ readonly insecureSkipVerify?: boolean; /** * keySecret defines the Secret containing the client key file for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#keySecret */ readonly keySecret?: ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret; /** * maxVersion defines the maximum acceptable TLS version. * * It requires Prometheus >= v2.41.0 or Thanos >= v0.31.0. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#maxVersion */ readonly maxVersion?: ServiceMonitorSpecEndpointsOauth2TlsConfigMaxVersion; /** * minVersion defines the minimum acceptable TLS version. * * It requires Prometheus >= v2.35.0 or Thanos >= v0.28.0. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#minVersion */ readonly minVersion?: ServiceMonitorSpecEndpointsOauth2TlsConfigMinVersion; /** * serverName is used to verify the hostname for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfig#serverName */ readonly serverName?: string; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfig' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfig(obj: ServiceMonitorSpecEndpointsOauth2TlsConfig | undefined): Record | undefined; /** * action to perform based on the regex matching. * * `Uppercase` and `Lowercase` actions require Prometheus >= v2.36.0. * `DropEqual` and `KeepEqual` actions require Prometheus >= v2.41.0. * * Default: "Replace" * * @schema ServiceMonitorSpecEndpointsRelabelingsAction */ export declare enum ServiceMonitorSpecEndpointsRelabelingsAction { /** replace */ REPLACE = "replace", /** keep */ KEEP = "keep", /** drop */ DROP = "drop", /** hashmod */ HASHMOD = "hashmod", /** labelmap */ LABELMAP = "labelmap", /** labeldrop */ LABELDROP = "labeldrop", /** labelkeep */ LABELKEEP = "labelkeep", /** lowercase */ LOWERCASE = "lowercase", /** uppercase */ UPPERCASE = "uppercase", /** keepequal */ KEEPEQUAL = "keepequal", /** dropequal */ DROPEQUAL = "dropequal" } /** * ca defines the Certificate authority used when verifying server certificates. * * @schema ServiceMonitorSpecEndpointsTlsConfigCa */ export interface ServiceMonitorSpecEndpointsTlsConfigCa { /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCa#configMap */ readonly configMap?: ServiceMonitorSpecEndpointsTlsConfigCaConfigMap; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCa#secret */ readonly secret?: ServiceMonitorSpecEndpointsTlsConfigCaSecret; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCa' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCa(obj: ServiceMonitorSpecEndpointsTlsConfigCa | undefined): Record | undefined; /** * cert defines the Client certificate to present when doing client-authentication. * * @schema ServiceMonitorSpecEndpointsTlsConfigCert */ export interface ServiceMonitorSpecEndpointsTlsConfigCert { /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCert#configMap */ readonly configMap?: ServiceMonitorSpecEndpointsTlsConfigCertConfigMap; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCert#secret */ readonly secret?: ServiceMonitorSpecEndpointsTlsConfigCertSecret; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCert' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCert(obj: ServiceMonitorSpecEndpointsTlsConfigCert | undefined): Record | undefined; /** * keySecret defines the Secret containing the client key file for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigKeySecret */ export interface ServiceMonitorSpecEndpointsTlsConfigKeySecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsTlsConfigKeySecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsTlsConfigKeySecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsTlsConfigKeySecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigKeySecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigKeySecret(obj: ServiceMonitorSpecEndpointsTlsConfigKeySecret | undefined): Record | undefined; /** * maxVersion defines the maximum acceptable TLS version. * * It requires Prometheus >= v2.41.0 or Thanos >= v0.31.0. * * @schema ServiceMonitorSpecEndpointsTlsConfigMaxVersion */ export declare enum ServiceMonitorSpecEndpointsTlsConfigMaxVersion { /** TLS10 */ TLS10 = "TLS10", /** TLS11 */ TLS11 = "TLS11", /** TLS12 */ TLS12 = "TLS12", /** TLS13 */ TLS13 = "TLS13" } /** * minVersion defines the minimum acceptable TLS version. * * It requires Prometheus >= v2.35.0 or Thanos >= v0.28.0. * * @schema ServiceMonitorSpecEndpointsTlsConfigMinVersion */ export declare enum ServiceMonitorSpecEndpointsTlsConfigMinVersion { /** TLS10 */ TLS10 = "TLS10", /** TLS11 */ TLS11 = "TLS11", /** TLS12 */ TLS12 = "TLS12", /** TLS13 */ TLS13 = "TLS13" } /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap */ export interface ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap { /** * The key to select. * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap#name */ readonly name?: string; /** * Specify whether the ConfigMap or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap(obj: ServiceMonitorSpecEndpointsOauth2ClientIdConfigMap | undefined): Record | undefined; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdSecret */ export interface ServiceMonitorSpecEndpointsOauth2ClientIdSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2ClientIdSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2ClientIdSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2ClientIdSecret(obj: ServiceMonitorSpecEndpointsOauth2ClientIdSecret | undefined): Record | undefined; /** * ca defines the Certificate authority used when verifying server certificates. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCa */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCa { /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCa#configMap */ readonly configMap?: ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCa#secret */ readonly secret?: ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCa' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCa(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCa | undefined): Record | undefined; /** * cert defines the Client certificate to present when doing client-authentication. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCert */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCert { /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCert#configMap */ readonly configMap?: ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCert#secret */ readonly secret?: ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCert' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCert(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCert | undefined): Record | undefined; /** * keySecret defines the Secret containing the client key file for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigKeySecret | undefined): Record | undefined; /** * maxVersion defines the maximum acceptable TLS version. * * It requires Prometheus >= v2.41.0 or Thanos >= v0.31.0. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigMaxVersion */ export declare enum ServiceMonitorSpecEndpointsOauth2TlsConfigMaxVersion { /** TLS10 */ TLS10 = "TLS10", /** TLS11 */ TLS11 = "TLS11", /** TLS12 */ TLS12 = "TLS12", /** TLS13 */ TLS13 = "TLS13" } /** * minVersion defines the minimum acceptable TLS version. * * It requires Prometheus >= v2.35.0 or Thanos >= v0.28.0. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigMinVersion */ export declare enum ServiceMonitorSpecEndpointsOauth2TlsConfigMinVersion { /** TLS10 */ TLS10 = "TLS10", /** TLS11 */ TLS11 = "TLS11", /** TLS12 */ TLS12 = "TLS12", /** TLS13 */ TLS13 = "TLS13" } /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCaConfigMap */ export interface ServiceMonitorSpecEndpointsTlsConfigCaConfigMap { /** * The key to select. * * @schema ServiceMonitorSpecEndpointsTlsConfigCaConfigMap#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsTlsConfigCaConfigMap#name */ readonly name?: string; /** * Specify whether the ConfigMap or its key must be defined * * @schema ServiceMonitorSpecEndpointsTlsConfigCaConfigMap#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCaConfigMap' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCaConfigMap(obj: ServiceMonitorSpecEndpointsTlsConfigCaConfigMap | undefined): Record | undefined; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCaSecret */ export interface ServiceMonitorSpecEndpointsTlsConfigCaSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsTlsConfigCaSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsTlsConfigCaSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsTlsConfigCaSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCaSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCaSecret(obj: ServiceMonitorSpecEndpointsTlsConfigCaSecret | undefined): Record | undefined; /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCertConfigMap */ export interface ServiceMonitorSpecEndpointsTlsConfigCertConfigMap { /** * The key to select. * * @schema ServiceMonitorSpecEndpointsTlsConfigCertConfigMap#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsTlsConfigCertConfigMap#name */ readonly name?: string; /** * Specify whether the ConfigMap or its key must be defined * * @schema ServiceMonitorSpecEndpointsTlsConfigCertConfigMap#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCertConfigMap' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCertConfigMap(obj: ServiceMonitorSpecEndpointsTlsConfigCertConfigMap | undefined): Record | undefined; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsTlsConfigCertSecret */ export interface ServiceMonitorSpecEndpointsTlsConfigCertSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsTlsConfigCertSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsTlsConfigCertSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsTlsConfigCertSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsTlsConfigCertSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsTlsConfigCertSecret(obj: ServiceMonitorSpecEndpointsTlsConfigCertSecret | undefined): Record | undefined; /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap { /** * The key to select. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap#name */ readonly name?: string; /** * Specify whether the ConfigMap or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCaConfigMap | undefined): Record | undefined; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCaSecret | undefined): Record | undefined; /** * configMap defines the ConfigMap containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap { /** * The key to select. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap#name */ readonly name?: string; /** * Specify whether the ConfigMap or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCertConfigMap | undefined): Record | undefined; /** * secret defines the Secret containing data to use for the targets. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret */ export interface ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret { /** * The key of the secret to select from. Must be a valid secret key. * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret#key */ readonly key: string; /** * Name of the referent. * This field is effectively required, but due to backwards compatibility is * allowed to be empty. Instances of this type with an empty value here are * almost certainly wrong. * More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret#name */ readonly name?: string; /** * Specify whether the Secret or its key must be defined * * @schema ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret#optional */ readonly optional?: boolean; } /** * Converts an object of type 'ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret' to JSON representation. */ export declare function toJson_ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret(obj: ServiceMonitorSpecEndpointsOauth2TlsConfigCertSecret | undefined): Record | undefined;