kubeapiserverexposure

package
v1.70.3 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2023 License: Apache-2.0, BSD-2-Clause, MIT, + 1 more Imports: 36 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// DefaultInterval is the default interval for retry operations.
	DefaultInterval = 5 * time.Second
	// DefaultTimeout is the default timeout and defines how long Gardener should wait
	// for a successful reconciliation of the service resource.
	DefaultTimeout = 10 * time.Minute
)

Functions

func AnyDeployedSNI

func AnyDeployedSNI(ctx context.Context, c client.Client) (bool, error)

AnyDeployedSNI returns true if any SNI is deployed in the cluster.

func NewIngress added in v1.68.0

func NewIngress(c client.Client, namespace string, values IngressValues) component.Deployer

NewIngress creates a new instance of Deployer for the ingress used to expose the kube-apiserver.

func NewInternalNameService added in v1.69.0

func NewInternalNameService(c client.Client, namespace string) component.Deployer

NewInternalNameService creates a new instance of Deployer for the service pointing to kubernetes.default.svc.cluster.local.

func NewSNI

func NewSNI(
	client client.Client,
	applier kubernetes.Applier,
	namespace string,
	valuesFunc func() *SNIValues,
) component.DeployWaiter

NewSNI creates a new instance of DeployWaiter which deploys Istio resources for kube-apiserver SNI access.

func NewService

func NewService(
	log logr.Logger,
	cl client.Client,
	values *ServiceValues,
	serviceKeyFunc func() client.ObjectKey,
	sniServiceKeyFunc func() client.ObjectKey,
	waiter retry.Ops,
	clusterIPFunc func(clusterIP string),
	ingressFunc func(ingressIP string),
	fullNetworkPolicies bool,
	clusterIP string,
) component.DeployWaiter

NewService creates a new instance of DeployWaiter for the Service used to expose the kube-apiserver. <waiter> is optional and defaulted to github.com/gardener/gardener/pkg/utils/retry.DefaultOps().

Types

type IngressValues added in v1.68.0

type IngressValues struct {
	// Host is the host where the kube-apiserver should be exposed.
	Host string
	// IngressClassName is the name of the ingress class.
	IngressClassName *string
	// ServiceName is the name of the service the ingress is using.
	ServiceName string
	// TLSSecretName is the name of the TLS secret.
	// If no secret is provided TLS is not terminated by nginx.
	TLSSecretName *string
}

IngressValues configure the kube-apiserver ingress.

type IstioIngressGateway

type IstioIngressGateway struct {
	Namespace string
	Labels    map[string]string
}

IstioIngressGateway contains the values for istio ingress gateway configuration.

type SNIValues

type SNIValues struct {
	Hosts                    []string
	NamespaceUID             types.UID
	APIServerClusterIP       string
	APIServerInternalDNSName string
	IstioIngressGateway      IstioIngressGateway
}

SNIValues configure the kube-apiserver service SNI.

type ServiceValues

type ServiceValues struct {
	// AnnotationsFunc is a function that returns annotations that should be added to the service.
	AnnotationsFunc func() map[string]string
	// SNIPhase is the current status of the SNI configuration.
	SNIPhase component.Phase
	// TopologyAwareRoutingEnabled indicates whether topology-aware routing is enabled for the kube-apiserver service.
	TopologyAwareRoutingEnabled bool
}

ServiceValues configure the kube-apiserver service.

Jump to

Keyboard shortcuts

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