ako_operator

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DeployInBootstrapCluster - defines if ako operator is deployed in bootstrap cluster
	DeployInBootstrapCluster = "bootstrap_cluster"

	// IsControlPlaneHAProvider - defines if ako operator is going to provide control plane HA
	IsControlPlaneHAProvider = "avi_control_plane_ha_provider"

	// ClusterControlPlaneAnnotations - defines cluster control plane endpoint
	ClusterControlPlaneAnnotations = "tkg.tanzu.vmware.com/cluster-controlplane-endpoint"

	// ControlPlaneEndpointPort - defines the control plane endpoint port
	ControlPlaneEndpointPort = "control_plane_endpoint_port"
)

Legacy cluster environment variables

View Source
const (
	// ClusterClassEnabled - helps check if cluster is classy based cluster when no cluster object create yet.
	ClusterClassEnabled = "cluster_class_enabled"

	// KubeVipLoadBalancerProvider - defines if cluster using kube-vip to implement load balancer
	// type of service
	KubeVipLoadBalancerProvider = "kubeVipLoadBalancerProvider"

	// AviAPIServerHAProvider - defines if ako operator is going to provide control plane HA
	AviAPIServerHAProvider = "aviAPIServerHAProvider"

	// ApiServerPort - defines the control plane endpoint
	ApiServerEndpoint = "apiServerEndpoint"

	// ApiServerPort - defines the control plane endpoint port
	ApiServerPort = "apiServerPort"
)

ClusterClass Env variables

Variables

This section is empty.

Functions

func ApplyClusterLabel

func ApplyClusterLabel(log logr.Logger, cluster *clusterv1.Cluster, obj *akoov1alpha1.AKODeploymentConfig)

applyClusterLabel applies the networking.tkg.tanzu.vmware.com/avi label to a Cluster

func GetAKODeploymentConfigForCluster

func GetAKODeploymentConfigForCluster(
	ctx context.Context,
	kclient client.Client,
	log logr.Logger,
	cluster *clusterv1.Cluster) (*akoov1alpha1.AKODeploymentConfig, error)

GetAKODeploymentConfigForCluster return the akodeloymentconfig object which selects current cluster

func GetControlPlaneEndpoint added in v1.7.0

func GetControlPlaneEndpoint(cluster *clusterv1.Cluster) (string, error)

GetControlPlaneEndpoint returns cluster's API server address

func GetControlPlaneEndpointPort

func GetControlPlaneEndpointPort(cluster *clusterv1.Cluster) (int32, error)

GetControlPlaneEndpointPort returns cluster's API server port default value is 6443

func IsBootStrapCluster

func IsBootStrapCluster() bool

func IsClusterClassBasedCluster added in v1.7.0

func IsClusterClassBasedCluster(cluster *clusterv1.Cluster) bool

IsClusterClassBasedCluster checks if a cluster is cluster class based cluster

func IsClusterClassEnabled added in v1.7.0

func IsClusterClassEnabled() bool

func IsControlPlaneVIPProvider added in v1.7.0

func IsControlPlaneVIPProvider(cluster *clusterv1.Cluster) (bool, error)

IsControlPlaneVIPProvider checks if NSX Advanced Load Balancer is cluster's endpoint VIP provider

func IsLegacyBootStrapCluster added in v1.7.0

func IsLegacyBootStrapCluster() bool

func IsLoadBalancerProvider added in v1.7.0

func IsLoadBalancerProvider(cluster *clusterv1.Cluster) (bool, error)

IsLoadBalancerProvider checks if NSX Advanced Load Balancer is cluster's load balancer implementation default value is true

func ListAkoDeploymentConfigSelectClusters

func ListAkoDeploymentConfigSelectClusters(
	ctx context.Context,
	kclient client.Client,
	log logr.Logger,
	obj *akoov1alpha1.AKODeploymentConfig) (*clusterv1.ClusterList, error)

ListAkoDeploymentConfigSelectClusters list all clusters enabled current akodeploymentconfig

func RemoveClusterLabel

func RemoveClusterLabel(log logr.Logger, cluster *clusterv1.Cluster)

removeClusterLabel removes the networking.tkg.tanzu.vmware.com/avi label from a Cluster

func SetControlPlaneEndpoint added in v1.7.0

func SetControlPlaneEndpoint(cluster *clusterv1.Cluster, endpoint string)

SetControlPlaneEndpoint sets cluster.spec.topology.variables.apiServerEndpoint

func SkipCluster

func SkipCluster(cluster *clusterv1.Cluster) bool

SkipCluster checks if akodeploymentconfig controller should skip reconciling this cluster or not

Types

This section is empty.

Jump to

Keyboard shortcuts

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