Skip to content

Prometheus Config Schema

Note

This is auto-generated documentation from a JSON schema that is under construction, this will improve over time.

Return to the root config schema

https://raw.githubusercontent.com/elastisys/compliantkubernetes-apps/main/config/schemas/config.yaml#/properties/prometheus

Configure Prometheus.

Prometheus automatically collects metrics via ServiceMonitors, PodMonitors, and Probes, and pushes metrics to Thanos for long term storage. Additionally Prometheus evaluates recording rules for both service and workload cluster, and all alerting rules for the workload cluster.

Note

Prometheus is installed in both service cluster and workload cluster, so this configuration applies there with some exceptions.

Abstract Extensible Status Identifiable Custom Properties Additional Properties Access Restrictions Defined In
Can be instantiated No Unknown status No Forbidden Forbidden none config/schemas/config.yaml*

TYPE:

object (Prometheus Config)

PROPERTIES:

Property Type Required Nullable Defined by
replicas number Optional cannot be null Welkin Apps Config
storage object Optional cannot be null Welkin Apps Config
retention object Optional cannot be null Welkin Apps Config
additionalScrapeConfigs array Optional cannot be null Welkin Apps Config
alertmanagerSpec object Optional cannot be null Welkin Apps Config
capacityManagementAlerts object Optional cannot be null Welkin Apps Config
diskAlerts object Optional cannot be null Welkin Apps Config
s3BucketAlerts object Optional cannot be null Welkin Apps Config
webhookAlerts object Optional cannot be null Welkin Apps Config
resources object Optional cannot be null Welkin Apps Config
tolerations array Optional cannot be null Welkin Apps Config
topologySpreadConstraints array Optional cannot be null Welkin Apps Config
nodeSelector object Optional cannot be null Welkin Apps Config
affinity object Optional cannot be null Welkin Apps Config

replicas

replicas

TYPE:

number (Prometheus Relicas)

DEFAULTS:

The default value is:

1

storage

Configure the persistent volume claim used for Promtheus storage.

storage

TYPE:

object (Prometheus Storage)

retention

Configure retention for Prometheus.

retention

TYPE:

object (Prometheus Retention)

additionalScrapeConfigs

Configure additional scrape configs for Prometheus.

Note

See the upstream documentation for reference.

additionalScrapeConfigs

TYPE:

array (Prometheus Additional Scrape Configs)

alertmanagerSpec

Configure service cluster Alertmanager.

Alertmanager receives alerts from Prometheus and Thanos and forwards them to the configured notification channel.

Note

Alertmanager is installed in both service cluster and workload cluster, however this configuration key only applies to the service cluster, use user.alertmanager to configure it in the workload cluster.

alertmanagerSpec

TYPE:

object (Alertmanager Config)

capacityManagementAlerts

Configure capacity management alerts.

capacityManagementAlerts

TYPE:

object (Capacity Management Alerts)

diskAlerts

Configure disk alerts.

diskAlerts

TYPE:

object (Disk Alerts)

s3BucketAlerts

Configure S3 bucket alerts.

s3BucketAlerts

TYPE:

object (S3 Bucket Alerts)

webhookAlerts

Configure webhook alerts.

webhookAlerts

TYPE:

object (Webhook Alerts)

resources

Resource requests are used by the kube-scheduler to pick a node to schedule pods on.

Limits are enforced. Resources are commonly 'cpu' and 'memory'.

resources

TYPE:

object (Kubernetes Resource Requirements)

EXAMPLES:

requests:
  memory: 128Mi
  cpu: 100m
limits:
  memory: 256Mi
  cpu: 250m

tolerations

Kubernetes Tolerations

Kubernetes taint and toleration

tolerations

TYPE:

an array of merged types (Details)

topologySpreadConstraints

TopologySpreadConstraints describes how pods should spread across topology domains.

topologySpreadConstraints

TYPE:

an array of merged types (Details)

nodeSelector

Kubernetes node selector

Kubernetes assign pod node

nodeSelector

TYPE:

object (Kubernetes Node Selector)

EXAMPLES:

kubernetes.io/os: linux

affinity

Affinity is a group of affinity scheduling rules.

affinity

TYPE:

object (Affinity)

Definitions

capacityManagementAlerts

Reference this group by using

{"$ref":"https://raw.githubusercontent.com/elastisys/compliantkubernetes-apps/main/config/schemas/config.yaml#/properties/prometheus/$defs/capacityManagementAlerts"}
Property Type Required Nullable Defined by
persistentVolume object Optional cannot be null Welkin Apps Config
persistentVolumeEnabled boolean Optional cannot be null Welkin Apps Config
persistentVolumeLimit number Optional cannot be null Welkin Apps Config
disklimit number Optional cannot be null Welkin Apps Config
requestlimit object Optional cannot be null Welkin Apps Config
requestlimitList array Optional cannot be null Welkin Apps Config
requestlimitTerm object Optional cannot be null Welkin Apps Config

persistentVolume

Configure capacity management alerts on persistent volumes.

persistentVolume

TYPE:

object (Capacity Management Alerts Persistent Volumes)

persistentVolumeEnabled

persistentVolumeEnabled

TYPE:

boolean (Capacity Management Alerts Persistent Volumes Enabled)

DEFAULTS:

The default value is:

true

persistentVolumeLimit

Alert when a persistent volume's usage reaches the limit in percent.

persistentVolumeLimit

TYPE:

number (Capacity Management Alerts Persistent Volumes Enabled)

DEFAULTS:

The default value is:

75

disklimit

Alert when a disk's usage reaches the limit in percent.

disklimit

TYPE:

number (Capacity Management Alerts Disk Limit)

DEFAULTS:

The default value is:

75

requestlimit

Alert when a node's resource requests reaches the limits in percent.

requestlimit

TYPE:

object (Capacity Management Alerts Request Limit)

requestlimitList

Configure a list of node patterns and request limits to alert for.

requestlimitList

TYPE:

object[] (Capacity Management Alerts Request Limit Term)

requestlimitTerm

Configure a node pattern and the request limit to alert for.

requestlimitTerm

TYPE:

object (Capacity Management Alerts Request Limit Term)

diskAlerts

Reference this group by using

{"$ref":"https://raw.githubusercontent.com/elastisys/compliantkubernetes-apps/main/config/schemas/config.yaml#/properties/prometheus/$defs/diskAlerts"}
Property Type Required Nullable Defined by
storage object Optional cannot be null Welkin Apps Config
inode object Optional cannot be null Welkin Apps Config
patternRules array Optional cannot be null Welkin Apps Config
patternRule object Optional cannot be null Welkin Apps Config
patterns object Optional cannot be null Welkin Apps Config
pattern object Optional cannot be null Welkin Apps Config
perf object Optional cannot be null Welkin Apps Config
perfEnabled boolean Optional cannot be null Welkin Apps Config
perfQueueSizeThreshold number Optional cannot be null Welkin Apps Config
perfReadWaitTimeThreshold number Optional cannot be null Welkin Apps Config
perfWriteWaitTimeThreshold number Optional cannot be null Welkin Apps Config

storage

Configure disk alerts based on storage usage.

storage

TYPE:

object (Disk Alerts Storage)

inode

Configure disk alerts based on inode usage.

inode

TYPE:

object (Disk Alerts Inode)

patternRules

Configure disk alerts when disk usage is predicted to reach the limit.

patternRules

TYPE:

object[] (Disk Alert Pattern Rule)

patternRule

Configure disk alerts when disk usage is predicted to reach the limit.

The hours key is only supported when configured under predictLinear.

patternRule

TYPE:

object (Disk Alert Pattern Rule)

patterns

Select applicable nodes and disks to include or exclude using patterns.

patterns

TYPE:

object (Disk Alert Patterns)

pattern

Select applicable nodes and disks using patterns.

pattern

TYPE:

object (Disk Alert Pattern)

perf

Configure performance disk alerts.

perf

TYPE:

object (Disk Alerts Perf)

perfEnabled

perfEnabled

TYPE:

boolean (Disk Alerts Perf Enabled)

perfQueueSizeThreshold

perfQueueSizeThreshold

TYPE:

number (Disk Alerts Perf Queue Size)

DEFAULTS:

The default value is:

0.5

perfReadWaitTimeThreshold

perfReadWaitTimeThreshold

TYPE:

number (Disk Alerts Perf Read Wait)

DEFAULTS:

The default value is:

0.01

perfWriteWaitTimeThreshold

perfWriteWaitTimeThreshold

TYPE:

number (Disk Alerts Perf Write Wait)

DEFAULTS:

The default value is:

0.1

s3BucketAlerts

Reference this group by using

{"$ref":"https://raw.githubusercontent.com/elastisys/compliantkubernetes-apps/main/config/schemas/config.yaml#/properties/prometheus/$defs/s3BucketAlerts"}
Property Type Required Nullable Defined by
objects object Optional cannot be null Welkin Apps Config
size object Optional cannot be null Welkin Apps Config
totalSize object Optional cannot be null Welkin Apps Config
exclude array Optional cannot be null Welkin Apps Config

objects

Alert when an S3 buckets reaches the set percentage of the set number of objects.

objects

TYPE:

object (S3 Bucket Alerts Objects)

size

Alert when an S3 bucket reaches the set percentage of the set size.

size

TYPE:

object (S3 Bucket Alerts Size)

totalSize

Alert when all S3 buckets reaches the set percentage of the set size.

totalSize

TYPE:

object (S3 Bucket Alerts Total Size)

exclude

Exclude buckets from S3 alerts.

exclude

TYPE:

string[] (S3 Bucket Name)

Return to the root config schema


Generated Sun Nov 17 03:51:36 UTC 2024 from elastisys/compliantkubernetes-apps@main