Help us shape the future of Go! Take the 2026 Go Developer Survey

alertmanager

package
v1.154.1 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: Apache-2.0 Imports: 37 Imported by: 8

Documentation

Index

Constants

View Source
const (

	// PortNameMetrics is the name of the metrics port.
	PortNameMetrics = "metrics"
)

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 CentralLoggingConfiguration

func CentralLoggingConfiguration() (component.CentralLoggingConfig, error)

CentralLoggingConfiguration returns a fluent-bit parser and filter for the alertmanager logs.

func GetLabels added in v1.93.0

func GetLabels(name string) map[string]string

GetLabels returns the labels for the given name.

Types

type ExposureValues

type ExposureValues struct {
	// AuthSecretName is the name of the auth secret.
	AuthSecretName string
	// AuthSecretManaged indicates whether the auth secret is managed by the secrets manager.
	AuthSecretManaged bool
	// Host is the hostname under which the AlertManager instance should be exposed.
	Host string
	// IsGardenCluster specifies whether the cluster is garden cluster.
	IsGardenCluster bool
	// IstioIngressGatewayLabels are the labels identifying the corresponding istio ingress gateway.
	IstioIngressGatewayLabels map[string]string
	// IstioIngressGatewayNamespace is the namespace of the istio ingress gateway.
	IstioIngressGatewayNamespace string
	// SecretsManager is the secrets manager used for generating the TLS certificate if no wildcard certificate is
	// provided.
	SecretsManager secretsmanager.Interface
	// SigningCA is the name of the CA that should be used to sign a self-signed server certificate. Only needed when
	// no wildcard certificate secret is provided.
	SigningCA string
	// 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
}

ExposureValues contains configuration for exposing this AlertManager instance via a VirtualService resource.

type Interface

type Interface interface {
	component.DeployWaiter
	// SetIngressAuthSecret sets the ingress authentication secret name and whether it is managed by the secrets manager.
	SetIngressAuthSecret(name string, managed bool)
	// SetIngressWildcardCertSecret sets the ingress wildcard certificate secret name.
	SetIngressWildcardCertSecret(*corev1.Secret)
}

Interface contains functions for an alertmanager deployer.

func New

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

New creates a new instance of DeployWaiter for the AlertManager.

type Values

type Values struct {
	// Name is the name of the AlertManager. It will be used for the resource names of AlertManager and ManagedResource.
	Name string
	// Image defines the container image of AlertManager.
	Image string
	// Version is the version of AlertManager.
	Version string
	// ClusterType is the type of the cluster.
	ClusterType component.ClusterType
	// PriorityClassName is the name of the priority class for the StatefulSet.
	PriorityClassName string
	// StorageCapacity is the storage capacity of AlertManager.
	StorageCapacity resource.Quantity
	// Replicas is the number of replicas.
	Replicas int32
	// RuntimeVersion is the Kubernetes version of the runtime cluster.
	RuntimeVersion *semver.Version
	// AlertingSMTPSecret is the alerting SMTP secret.
	AlertingSMTPSecret *corev1.Secret
	// EmailReceivers is a list of email addresses to which alerts should be sent. If this list is empty, the alerts
	// will be sent to the email address in `.data.to` in the alerting SMTP secret.
	EmailReceivers []string
	// ExternalExposure contains configuration for exposing this AlertManager instance via a VirtualService resource.
	ExternalExposure *ExposureValues
}

Values contains configuration values for the AlertManager resources.

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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