prometheus

package
v1.91.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2024 License: Apache-2.0, BSD-2-Clause, MIT, + 1 more Imports: 31 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// ServicePortName is the name of the port in the Service specification.
	ServicePortName = "web"
)

Variables

View Source
var TimeoutWaitForManagedResource = 5 * time.Minute

TimeoutWaitForManagedResource is the timeout used while waiting for the ManagedResources to become healthy or deleted.

Functions

func New

func New(log logr.Logger, client client.Client, namespace string, values Values) component.DeployWaiter

New creates a new instance of DeployWaiter for the prometheus.

Types

type AlertingValues

type AlertingValues struct {
	// AlertmanagerName is the name of the alertmanager to which alerts should be sent.
	AlertmanagerName string
}

AlertingValues contains alerting configuration for this Prometheus instance.

type CentralConfigs

type CentralConfigs struct {
	// AdditionalScrapeConfigs are additional scrape configs which cannot be modelled with the CRDs of the Prometheus
	// operator.
	AdditionalScrapeConfigs []string
	// PrometheusRules is a list of central PrometheusRule objects for this prometheus instance.
	PrometheusRules []*monitoringv1.PrometheusRule
	// ScrapeConfigs is a list of central ScrapeConfig objects for this prometheus instance.
	ScrapeConfigs []*monitoringv1alpha1.ScrapeConfig
	// ServiceMonitors is a list of central ServiceMonitor objects for this prometheus instance.
	ServiceMonitors []*monitoringv1.ServiceMonitor
	// PodMonitors is a list of central PodMonitor objects for this prometheus instance.
	PodMonitors []*monitoringv1.PodMonitor
}

CentralConfigs contains configuration for this Prometheus instance that is created together with it. This should only contain configuration that cannot be directly assigned to another component package.

type IngressValues

type IngressValues struct {
	// AuthSecretName is the name of the auth secret.
	AuthSecretName string
	// Host is the hostname under which the Prometheus instance should be exposed.
	Host string
	// SecretsManager is the secrets manager used for generating the TLS certificate if no wildcard certificate is
	// provided.
	SecretsManager secretsmanager.Interface
	// WildcardCertSecretName is name of a secret containing the wildcard TLS certificate which is issued for the
	// ingress domain. If not provided, a self-signed server certificate will be created.
	WildcardCertSecretName *string
}

IngressValues contains configuration for exposing this Prometheus instance via an Ingress resource.

type Values

type Values struct {
	// Name is the name of the prometheus. It will be used for the resource names of Prometheus and ManagedResource.
	Name string
	// Image defines the container image of prometheus.
	Image string
	// Version is the version of prometheus.
	Version string
	// PriorityClassName is the name of the priority class for the deployment.
	PriorityClassName string
	// StorageCapacity is the storage capacity of Prometheus.
	StorageCapacity resource.Quantity
	// Retention is the duration for the data retention.
	Retention *monitoringv1.Duration
	// RetentionSize is the size for the data retention.
	RetentionSize monitoringv1.ByteSize
	// VPAMinAllowed defines the resource list for the minAllowed field for the prometheus container resource policy.
	VPAMinAllowed *corev1.ResourceList
	// ExternalLabels is the set of external labels for the Prometheus configuration.
	ExternalLabels map[string]string
	// AdditionalPodLabels is a map containing additional labels for the created pods.
	AdditionalPodLabels map[string]string
	// CentralConfigs contains configuration for this Prometheus instance that is created together with it. This should
	// only contain configuration that cannot be directly assigned to another component package.
	CentralConfigs CentralConfigs
	// IngressValues contains configuration for exposing this Prometheus instance via an Ingress resource.
	Ingress *IngressValues
	// Alerting contains alerting configuration for this Prometheus instance.
	Alerting *AlertingValues
	// AdditionalResources contains any additional resources which get added to the ManagedResource.
	AdditionalResources []client.Object

	// DataMigration is a struct for migrating data from existing disks.
	// TODO(rfranzke): Remove this as soon as the PV migration code is removed.
	DataMigration monitoring.DataMigration
}

Values contains configuration values for the prometheus resources.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL