provisioners

package
v0.0.0-...-72a3024 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2026 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultMgrImageName = "gcr.io/datadoghq/operator"
	DefaultMgrImgTag    = "latest"
	DefaultMgrFileName  = "e2e-manager.yaml"
	UserData            = `` /* 584-byte string literal not displayed */

)

Variables

View Source
var (
	NewMgrKustomizeDirPath = filepath.Join(e2ecommon.ProjectRootPath, "config", "new-e2e")
)

Functions

func EKSProvisioner

EKSProvisioner creates a new EKS provisioner for E2E tests

func GKEProvisioner

GKEProvisioner creates a new operator-focused GKE provisioner.

func KubernetesProvisioner

KubernetesProvisioner generic Kubernetes provisioner wrapper that creates a new provisioner Inspired by https://github.com/DataDog/datadog-agent/blob/main/test/e2e-framework/testing/provisioners/aws/kubernetes/kindvm/kind.go

func KustomizeWorkloadAppFunc

func KustomizeWorkloadAppFunc(name string, extraKustomizeResources []string) func(e config.Env, kubeProvider *kubernetes.Provider) (*kubeComp.Workload, error)

KustomizeWorkloadAppFunc Installs the operator e2e kustomize directory and any extra kustomize resources

func UpdateKustomization

func UpdateKustomization(kustomizeDirPath string, kustomizeResourcePaths []string) error

updateKustomization Updates kustomization.yaml file in given kustomize directory with extra resources and image name and tag if `IMG` environment variable is set.

func YAMLWorkloadAppFunc

func YAMLWorkloadAppFunc(yamlWorkload YAMLWorkload) func(e config.Env, kubeProvider *kubernetes.Provider) (*kubeComp.Workload, error)

YAMLWorkloadAppFunc Applies a Kubernetes resource yaml file

Types

type EKSProvisionerOption

type EKSProvisionerOption func(params *EKSProvisionerParams) error

EKSProvisionerOption is a function that modifies the EKSProvisionerParams

func WithEKSExtraConfigParams

func WithEKSExtraConfigParams(configMap runner.ConfigMap) EKSProvisionerOption

WithEKSExtraConfigParams adds extra config parameters to the environment

func WithEKSK8sVersion

func WithEKSK8sVersion(k8sVersion string) EKSProvisionerOption

WithEKSK8sVersion sets the Kubernetes version for the EKS cluster

func WithEKSLinuxARMNodeGroup

func WithEKSLinuxARMNodeGroup() EKSProvisionerOption

WithEKSLinuxARMNodeGroup adds a Linux (arm64) node group to the EKS cluster

func WithEKSLinuxNodeGroup

func WithEKSLinuxNodeGroup() EKSProvisionerOption

WithEKSLinuxNodeGroup adds a Linux (amd64) node group to the EKS cluster

func WithEKSName

func WithEKSName(name string) EKSProvisionerOption

WithEKSName sets the name of the EKS provisioner

type EKSProvisionerParams

type EKSProvisionerParams struct {
	// contains filtered or unexported fields
}

EKSProvisionerParams contains all the parameters needed to create an EKS environment

type GKEProvisionerOption

type GKEProvisionerOption func(params *GKEProvisionerParams) error

GKEProvisionerOption is a function that modifies GKEProvisionerParams.

func WithGKEAutopilot

func WithGKEAutopilot() GKEProvisionerOption

WithGKEAutopilot creates a GKE Autopilot cluster.

func WithGKEDDAOptions

func WithGKEDDAOptions(opts ...agentwithoperatorparams.Option) GKEProvisionerOption

WithGKEDDAOptions adds options to the DatadogAgent resource.

func WithGKEExtraConfigParams

func WithGKEExtraConfigParams(configMap runner.ConfigMap) GKEProvisionerOption

WithGKEExtraConfigParams adds extra Pulumi config parameters to the environment.

func WithGKEFakeIntakeOptions

func WithGKEFakeIntakeOptions(opts ...gcpfakeintake.Option) GKEProvisionerOption

WithGKEFakeIntakeOptions adds options to the fake intake VM.

func WithGKEK8sVersion

func WithGKEK8sVersion(k8sVersion string) GKEProvisionerOption

WithGKEK8sVersion sets the Kubernetes version for the GKE cluster.

func WithGKEKustomizeResources

func WithGKEKustomizeResources(k []string) GKEProvisionerOption

WithGKEKustomizeResources adds extra kustomize resources.

func WithGKEName

func WithGKEName(name string) GKEProvisionerOption

WithGKEName sets the name of the GKE provisioner.

func WithGKEOperatorOptions

func WithGKEOperatorOptions(opts ...operatorparams.Option) GKEProvisionerOption

WithGKEOperatorOptions adds options to the Datadog Operator installation.

func WithGKEOptions

func WithGKEOptions(opts ...gcpgke.Option) GKEProvisionerOption

WithGKEOptions adds options to the GKE cluster.

func WithGKETestName

func WithGKETestName(name string) GKEProvisionerOption

WithGKETestName sets the name of the test kustomize workload.

func WithGKEWorkloadApp

func WithGKEWorkloadApp(appFunc func(e config.Env, kubeProvider *kubernetes.Provider) (*kubeComp.Workload, error)) GKEProvisionerOption

WithGKEWorkloadApp adds a workload app to the environment.

func WithGKEYAMLWorkload

func WithGKEYAMLWorkload(yamlWorkload YAMLWorkload) GKEProvisionerOption

WithGKEYAMLWorkload adds a workload app to the environment for a YAML file.

func WithoutGKEDDA

func WithoutGKEDDA() GKEProvisionerOption

WithoutGKEDDA removes the DatadogAgent resource.

func WithoutGKEFakeIntake

func WithoutGKEFakeIntake() GKEProvisionerOption

WithoutGKEFakeIntake removes the fake intake.

func WithoutGKEOperator

func WithoutGKEOperator() GKEProvisionerOption

WithoutGKEOperator removes the Datadog Operator resource.

type GKEProvisionerParams

type GKEProvisionerParams struct {
	// contains filtered or unexported fields
}

GKEProvisionerParams contains all the parameters needed to create a GKE environment.

type KubernetesProvisionerOption

type KubernetesProvisionerOption func(params *KubernetesProvisionerParams) error

KubernetesProvisionerOption is a function that modifies the KubernetesProvisionerParams

func WithDDAOptions

WithDDAOptions adds options to the DatadogAgent resource

func WithExtraConfigParams

func WithExtraConfigParams(configMap runner.ConfigMap) KubernetesProvisionerOption

WithExtraConfigParams adds extra config parameters to the environment

func WithK8sVersion

func WithK8sVersion(k8sVersion string) KubernetesProvisionerOption

WithK8sVersion sets the kubernetes version

func WithKindWorkerNodes

func WithKindWorkerNodes(nodes ...kubeComp.KindWorkerNode) KubernetesProvisionerOption

WithKindWorkerNodes configures the kind cluster worker nodes with custom labels and taints applied at cluster-creation time (via kubeadm). Use this to test workloads that depend on node topology, e.g. nodes pre-tainted with the agent-not-ready startup taint for the untaint controller.

func WithKustomizeResources

func WithKustomizeResources(k []string) KubernetesProvisionerOption

WithKustomizeResources adds extra kustomize resources

func WithLocal

func WithLocal(local bool) KubernetesProvisionerOption

WithLocal uses the localKindRunFunc to create a local kind environment

func WithName

func WithName(name string) KubernetesProvisionerOption

WithName sets the name of the provisioner

func WithOperatorOptions

func WithOperatorOptions(opts ...operatorparams.Option) KubernetesProvisionerOption

WithOperatorOptions adds options to the DatadogAgent resource

func WithTestName

func WithTestName(name string) KubernetesProvisionerOption

WithTestName sets the name of the test

func WithWorkloadApp

func WithWorkloadApp(appFunc func(e config.Env, kubeProvider *kubernetes.Provider) (*kubeComp.Workload, error)) KubernetesProvisionerOption

WithWorkloadApp adds a workload app to the environment

func WithYAMLWorkload

func WithYAMLWorkload(yamlWorkload YAMLWorkload) KubernetesProvisionerOption

WithYAMLWorkload adds a workload app to the environment for given YAML file path

func WithoutDDA

func WithoutDDA() KubernetesProvisionerOption

WithoutDDA removes the DatadogAgent resource

func WithoutFakeIntake

func WithoutFakeIntake() KubernetesProvisionerOption

WithoutFakeIntake removes the fake intake

func WithoutOperator

func WithoutOperator() KubernetesProvisionerOption

WithoutOperator removes the Datadog Operator resource

type KubernetesProvisionerParams

type KubernetesProvisionerParams struct {
	// contains filtered or unexported fields
}

KubernetesProvisionerParams contains all the parameters needed to create a Kubernetes environment

type YAMLWorkload

type YAMLWorkload struct {
	Name string
	Path string
}

YAMLWorkload defines the parameters for a Kubernetes resource's YAML file

Jump to

Keyboard shortcuts

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