e2ecluster

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package e2ecluster resolves the isolated kind environment used by the e2e suite.

Package e2ecluster resolves the isolated kind environment used by the e2e suite.

Index

Constants

View Source
const (
	GatewayAPIChannelStandard     = "standard"
	GatewayAPIChannelExperimental = "experimental"
)

Variables

This section is empty.

Functions

func GatewayAPIHelmArgs

func GatewayAPIHelmArgs(channel string) ([]string, error)

GatewayAPIHelmArgs enables chart validation for the installed CRD channel.

func GatewayAPIInstallArgs

func GatewayAPIInstallArgs(version, channel, kubeconfig string) ([]string, error)

GatewayAPIInstallArgs returns kubectl arguments for one upstream CRD channel.

func HasTCPListener

func HasTCPListener(table string, port int) (bool, error)

HasTCPListener reads a Linux /proc/net/tcp or tcp6 table.

func SetTrafficEndpoint

func SetTrafficEndpoint(endpoint TrafficEndpoint) error

SetTrafficEndpoint selects the owned cluster's NodePorts before tests start.

func WithControllerEnv

func WithControllerEnv(values []byte, name, value string) ([]byte, error)

WithControllerEnv updates one environment variable without replacing its neighbours.

Types

type Config

type Config struct {
	ClusterName     string
	KubeconfigPath  string
	DockerNetwork   string
	NetworkLabels   map[string]string
	ExposeHostPorts bool
	RequireNew      bool
}

Config identifies the kind resources owned by one e2e suite invocation.

func Default

func Default() Config

Default returns the established e2e cluster settings.

func Load

func Load() (Config, error)

Load accepts either the established defaults or one complete isolation tuple.

func (Config) KindConfig

func (c Config) KindConfig() string

KindConfig omits host mappings when another local kind cluster may own them.

func (Config) WriteKubeconfig

func (c Config) WriteKubeconfig(contents []byte) error

WriteKubeconfig never replaces a path owned by another isolated run.

type ControllerScale

type ControllerScale struct {
	Name      string `json:"name"`
	Namespace string `json:"namespace"`
	Replicas  int64  `json:"replicas"`
}

ControllerScale is the requested controller size before staged installation.

func StageControllerStartup

func StageControllerStartup(manifests []byte) ([]byte, ControllerScale, error)

StageControllerStartup changes only the controller Deployment's initial size.

type TrafficEndpoint

type TrafficEndpoint struct {
	Host      string
	HTTPPort  int
	HTTPSPort int
}

func ResolveTrafficEndpoint

func ResolveTrafficEndpoint() (TrafficEndpoint, error)

ResolveTrafficEndpoint refuses host-port fallback for an isolated cluster.

Jump to

Keyboard shortcuts

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