constants

package
v1.18.0 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Liveness probe default config
	DefaultLivenessProbeInitialDelaySeconds int32 = 15
	DefaultLivenessProbePeriodSeconds       int32 = 15
	DefaultLivenessProbeTimeoutSeconds      int32 = 5
	DefaultLivenessProbeSuccessThreshold    int32 = 1
	DefaultLivenessProbeFailureThreshold    int32 = 6
	DefaultLivenessProbeHTTPPath                  = "/live"

	// Readiness probe default config
	DefaultReadinessProbeInitialDelaySeconds int32 = 15
	DefaultReadinessProbePeriodSeconds       int32 = 15
	DefaultReadinessProbeTimeoutSeconds      int32 = 5
	DefaultReadinessProbeSuccessThreshold    int32 = 1
	DefaultReadinessProbeFailureThreshold    int32 = 6
	DefaultReadinessProbeHTTPPath                  = "/ready"

	// Startup probe default config
	DefaultStartupProbeInitialDelaySeconds int32 = 15
	DefaultStartupProbePeriodSeconds       int32 = 15
	DefaultStartupProbeTimeoutSeconds      int32 = 5
	DefaultStartupProbeSuccessThreshold    int32 = 1
	DefaultStartupProbeFailureThreshold    int32 = 6
	DefaultStartupProbeHTTPPath                  = "/startup"

	// Agent Data plane default liveness/readiness probe configs
	DefaultADPLivenessProbeInitialDelaySeconds int32 = 5
	DefaultADPLivenessProbePeriodSeconds       int32 = 5
	DefaultADPLivenessProbeTimeoutSeconds      int32 = 5
	DefaultADPLivenessProbeSuccessThreshold    int32 = 1
	DefaultADPLivenessProbeFailureThreshold    int32 = 12

	DefaultADPReadinessProbeInitialDelaySeconds int32 = 5
	DefaultADPReadinessProbePeriodSeconds       int32 = 5
	DefaultADPReadinessProbeTimeoutSeconds      int32 = 5
	DefaultADPReadinessProbeSuccessThreshold    int32 = 1
	DefaultADPReadinessProbeFailureThreshold    int32 = 12

	// DefaultAgentHealthPort default agent health port
	DefaultAgentHealthPort int32 = 5555

	DefaultADPHealthPort = 5100

	// DefaultApmPort default apm port
	DefaultApmPort = 8126
	// DefaultApmPortName default apm port name
	DefaultApmPortName = "traceport"

	// DefaultAgentResourceSuffix use as suffix for agent resource naming
	DefaultAgentResourceSuffix = "agent"
	// DefaultClusterAgentResourceSuffix use as suffix for cluster-agent resource naming
	DefaultClusterAgentResourceSuffix = "cluster-agent"
	// DefaultClusterChecksRunnerResourceSuffix use as suffix for cluster-checks-runner resource naming
	DefaultClusterChecksRunnerResourceSuffix = "cluster-checks-runner"
)
View Source
const (
	// MD5AgentDeploymentProviderLabelKey label key is used to identify which provider is being used
	MD5AgentDeploymentProviderLabelKey = "agent.datadoghq.com/provider"
	// MD5AgentDeploymentAnnotationKey annotation key used on a Resource in order to identify which AgentDeployment have been used to generate it.
	MD5AgentDeploymentAnnotationKey = "agent.datadoghq.com/agentspechash"
	// MD5DDAIDeploymentAnnotationKey annotation key is used on a DatadogAgentInternal resource to identify if changes have been made to the spec.
	MD5DDAIDeploymentAnnotationKey = "agent.datadoghq.com/ddaispechash"
	// MD5ChecksumAnnotationKey annotation key is used to identify customConfig configurations
	MD5ChecksumAnnotationKey = "checksum/%s-custom-config"
)

Labels

View Source
const (
	DDAPIKey      = "DD_API_KEY"
	DDAppKey      = "DD_APP_KEY"
	DDddURL       = "DD_DD_URL"
	DDURL         = "DD_URL"
	DDSite        = "DD_SITE"
	DDClusterName = "DD_CLUSTER_NAME"
	DDLogLevel    = "DD_LOG_LEVEL"
	DDHostName    = "DD_HOSTNAME"
)
View Source
const (
	ProfileLabelKey = "agent.datadoghq.com/datadogagentprofile"
)

Profiles

Variables

This section is empty.

Functions

func GetAgentServiceAccount

func GetAgentServiceAccount(objName string, ddaSpec *v2alpha1.DatadogAgentSpec) string

GetAgentServiceAccount returns the agent service account name

func GetClusterAgentServiceAccount

func GetClusterAgentServiceAccount(objName string, ddaSpec *v2alpha1.DatadogAgentSpec) string

GetClusterAgentServiceAccount return the cluster-agent serviceAccountName

func GetClusterChecksRunnerServiceAccount

func GetClusterChecksRunnerServiceAccount(objName string, ddaSpec *v2alpha1.DatadogAgentSpec) string

GetClusterChecksRunnerServiceAccount return the cluster-checks-runner service account name

func GetConfName

func GetConfName(owner metav1.Object, conf *v2alpha1.CustomConfig, defaultName string) string

GetConfName get the name of the Configmap for a CustomConfigSpec

func GetDDAName added in v1.18.0

func GetDDAName(dda metav1.Object) string

GetDDAName returns the name of the DDA from DDAI labels or directly from the DDA

func GetDefaultAgentDataPlaneLivenessProbe

func GetDefaultAgentDataPlaneLivenessProbe() *corev1.Probe

GetDefaultAgentDataPlaneLivenessProbe creates a defaulted liveness probe for Agent Data Plane

func GetDefaultAgentDataPlaneReadinessProbe

func GetDefaultAgentDataPlaneReadinessProbe() *corev1.Probe

GetDefaultAgentDataPlaneReadinessProbe creates a defaulted readiness probe for Agent Data Plane

func GetDefaultLivenessProbe

func GetDefaultLivenessProbe() *corev1.Probe

GetDefaultLivenessProbe creates a defaulted LivenessProbe

func GetDefaultReadinessProbe

func GetDefaultReadinessProbe() *corev1.Probe

GetDefaultReadinessProbe creates a defaulted ReadinessProbe

func GetDefaultStartupProbe

func GetDefaultStartupProbe() *corev1.Probe

GetDefaultStartupProbe creates a defaulted StartupProbe

func GetDefaultTraceAgentProbe

func GetDefaultTraceAgentProbe() *corev1.Probe

GetDefaultTraceAgentProbe creates a defaulted liveness/readiness probe for the Trace Agent

func GetLocalAgentServiceName

func GetLocalAgentServiceName(objName string, ddaSpec *v2alpha1.DatadogAgentSpec) string

GetLocalAgentServiceName returns the name used for the local agent service

func GetServiceAccountByComponent added in v1.15.0

func GetServiceAccountByComponent(objName string, ddaSpec *v2alpha1.DatadogAgentSpec, component v2alpha1.ComponentName) string

GetServiceAccountByComponent returns the service account name for a given component

func IsCCREnabled

func IsCCREnabled(ddaSpec *v2alpha1.DatadogAgentSpec) bool

IsCCREnabled returns whether the DDA should use Cluster Checks Runners

func IsClusterChecksEnabled

func IsClusterChecksEnabled(ddaSpec *v2alpha1.DatadogAgentSpec) bool

IsClusterChecksEnabled returns whether the DDA should use cluster checks

func IsHostNetworkEnabled

func IsHostNetworkEnabled(ddaSpec *v2alpha1.DatadogAgentSpec, component v2alpha1.ComponentName) bool

IsHostNetworkEnabled returns whether the pod should use the host's network namespace

func IsNetworkPolicyEnabled

func IsNetworkPolicyEnabled(ddaSpec *v2alpha1.DatadogAgentSpec) (bool, v2alpha1.NetworkPolicyFlavor)

IsNetworkPolicyEnabled returns whether a network policy should be created and which flavor to use

Types

This section is empty.

Jump to

Keyboard shortcuts

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