test

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultCredentials

func DefaultCredentials() *datadoghqv1alpha1.AgentCredentials

DefaultCredentials generate an AgentCredentials instance for test purpose

func NewAPIService

func NewAPIService(ns, name string, opts *NewAPIServiceOptions) *apiregistrationv1.APIService

NewAPIService returns new apiregistrationv1.APIService instance

func NewClusterAgentDeployment

func NewClusterAgentDeployment(ns, name string, options *NewDeploymentOptions) *appsv1.Deployment

NewClusterAgentDeployment return new Cluster Agent Deployment instance for testing purpose

func NewDefaultedDatadogAgent

func NewDefaultedDatadogAgent(ns, name string, options *NewDatadogAgentOptions) *datadoghqv1alpha1.DatadogAgent

NewDefaultedDatadogAgent returns an initialized and defaulted DatadogAgent for testing purpose

func NewExtendedDaemonSet

func NewExtendedDaemonSet(ns, name string, options *NewExtendedDaemonSetOptions) *edsdatadoghqv1alpha1.ExtendedDaemonSet

NewExtendedDaemonSet return new ExtendedDDaemonset instance for testing purpose

func NewSecret

func NewSecret(ns, name string, opts *NewSecretOptions) *corev1.Secret

NewSecret returns new Secret instance

func NewService

func NewService(ns, name string, opts *NewServiceOptions) *corev1.Service

NewService returns new corev1.Service instance

Types

type NewAPIServiceOptions

type NewAPIServiceOptions struct {
	CreationTime *time.Time
	Annotations  map[string]string
	Labels       map[string]string
	Spec         *apiregistrationv1.APIServiceSpec
}

NewAPIServiceOptions used to provide options to the NewAPIService function

type NewDatadogAgentOptions

type NewDatadogAgentOptions struct {
	Labels                           map[string]string
	Annotations                      map[string]string
	Status                           *datadoghqv1alpha1.DatadogAgentStatus
	UseEDS                           bool
	ClusterAgentEnabled              bool
	ClusterAgentConfd                *datadoghqv1alpha1.ClusterAgentConfig
	MetricsServerEnabled             bool
	MetricsServerPort                int32
	MetricsServerEndpoint            string
	MetricsServerUseDatadogMetric    bool
	MetricsServerWPAController       bool
	MetricsServerCredentials         *datadoghqv1alpha1.DatadogCredentials
	ClusterChecksEnabled             bool
	KubeStateMetricsCore             *datadoghqv1alpha1.KubeStateMetricsCore
	NodeAgentConfig                  *datadoghqv1alpha1.NodeAgentConfig
	APMEnabled                       bool
	ProcessEnabled                   bool
	ProcessCollectionEnabled         bool
	OrchestratorExplorerDisabled     bool
	SystemProbeEnabled               bool
	SystemProbeSeccompProfileName    string
	SystemProbeAppArmorProfileName   string
	SystemProbeTCPQueueLengthEnabled bool
	SystemProbeOOMKillEnabled        bool
	Creds                            *datadoghqv1alpha1.AgentCredentials
	ClusterName                      *string
	Confd                            *datadoghqv1alpha1.ConfigDirSpec
	Checksd                          *datadoghqv1alpha1.ConfigDirSpec
	Volumes                          []corev1.Volume
	VolumeMounts                     []corev1.VolumeMount
	ClusterAgentVolumes              []corev1.Volume
	ClusterAgentVolumeMounts         []corev1.VolumeMount
	ClusterAgentEnvVars              []corev1.EnvVar
	CustomConfig                     string
	SystemProbeCustomConfigMapName   string
	AgentDaemonsetName               string
	ClusterAgentDeploymentName       string
	ClusterChecksRunnerEnabled       bool
	ClusterChecksRunnerVolumes       []corev1.Volume
	ClusterChecksRunnerVolumeMounts  []corev1.VolumeMount
	ClusterChecksRunnerEnvVars       []corev1.EnvVar
	APIKeyExistingSecret             string
	APISecret                        *commonv1.SecretConfig
	Site                             string
	HostPort                         int32
	HostNetwork                      bool
	AdmissionControllerEnabled       bool
	AdmissionMutateUnlabelled        bool
	AdmissionServiceName             string
	AdmissionCommunicationMode       string
	ComplianceEnabled                bool
	ComplianceCheckInterval          metav1.Duration
	ComplianceConfigDir              *datadoghqv1alpha1.ConfigDirSpec
	RuntimeSecurityEnabled           bool
	RuntimeSyscallMonitorEnabled     bool
	RuntimePoliciesDir               *datadoghqv1alpha1.ConfigDirSpec
	SecurityContext                  *corev1.PodSecurityContext
	CreateNetworkPolicy              bool
	NetworkPolicyFlavor              datadoghqv1alpha1.NetworkPolicyFlavor
	AgentSpecAdditionalLabels        map[string]string
	AgentSpecAdditionalAnnotations   map[string]string
	Features                         *datadoghqv1alpha1.DatadogFeatures
	ClusterAgentReplicas             *int32
	ClusterChecksRunnerReplicas      *int32
}

NewDatadogAgentOptions set of option for the DatadogAgent creation

type NewDeploymentOptions

type NewDeploymentOptions struct {
	CreationTime           *time.Time
	Annotations            map[string]string
	Labels                 map[string]string
	ForceAvailableReplicas *int32
}

NewDeploymentOptions set of option for the Deployment creation

type NewExtendedDaemonSetOptions

type NewExtendedDaemonSetOptions struct {
	CreationTime *time.Time
	Annotations  map[string]string
	Labels       map[string]string
	Canary       *edsdatadoghqv1alpha1.ExtendedDaemonSetSpecStrategyCanary
	Status       *edsdatadoghqv1alpha1.ExtendedDaemonSetStatus
}

NewExtendedDaemonSetOptions set of option for the ExtendedDaemonset creation

type NewSecretOptions

type NewSecretOptions struct {
	CreationTime *time.Time
	Annotations  map[string]string
	Labels       map[string]string
	Data         map[string][]byte
}

NewSecretOptions used to provide option to the NewSecret function

type NewServiceOptions

type NewServiceOptions struct {
	CreationTime *time.Time
	Annotations  map[string]string
	Labels       map[string]string
	Spec         *corev1.ServiceSpec
}

NewServiceOptions used to provide options to the NewService function

Jump to

Keyboard shortcuts

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