Documentation
¶
Index ¶
- Constants
- Variables
- func AKOControlConfig() *akoControlConfig
- func AnnotateNamespaceWithInfraSetting(namespace, infraSettingName string) error
- func AnnotateSystemNamespaceWithInfraSetting()
- func AutoAnnotateNPLSvc() bool
- func AviDelete(client *clients.AviClient, uri string, retryNum ...int) error
- func AviGet(client *clients.AviClient, uri string, response interface{}, retryNum ...int) error
- func AviGetCollectionRaw(client *clients.AviClient, uri string, retryNum ...int) (session.AviCollectionResult, error)
- func AviGetCollectionRawWithTenantSwitch(client *clients.AviClient, uri string) (session.AviCollectionResult, error)
- func AviGetRaw(client *clients.AviClient, uri string, retryNum ...int) ([]byte, error)
- func AviPost(client *clients.AviClient, uri string, payload interface{}, ...) error
- func AviPut(client *clients.AviClient, uri string, payload interface{}, ...) error
- func CheckAndSetGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
- func CheckAndSetIngressFinalizer(ing *networkingv1.Ingress)
- func CheckAndSetSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
- func CheckAndShortenLabelToFollowRFC1035(svcName string, svcNamespace string) (string, string)
- func CheckConstraintsForRFC(name string, pattern string, maxlength int) bool
- func CheckForInvalidCredentials(uri string, err error)
- func CheckObjectNameLength(objName, objType string) bool
- func CheckRFC1035(name string) bool
- func CompareVersions(v1, cmpSign, v2 string) bool
- func ContainsFinalizer(o metav1.Object, finalizer string) bool
- func CorrectLabelToSatisfyRFC1035(name *string, prefix string)
- func CreateAviInfraSetting(name, network, t1lr, project string) (*akov1beta1.AviInfraSetting, error)
- func CreateIstioSecretFromCert(name string, kc kubernetes.Interface)
- func DSChecksum(pgrefs []string, markers []*models.RoleFilterMatchLabel, populateCache bool) uint32
- func DecrementQueueCounter(queueName string)
- func Difference(a, b []string) []string
- func Encode(s, objType string) string
- func ExtractTypeNameNamespace(key string) (string, string, string)
- func FetchSEGroupWithMarkerSet(client *clients.AviClient, overrideUri ...NextPage) (error, string)
- func GetAKOIDPrefix() string
- func GetAKOUser() string
- func GetAdminTenant() string
- func GetAdvL4PoolName(svcName, namespace, gwName, protocol string, port int32) string
- func GetAdvancedL4() bool
- func GetAkoApiServerPort() string
- func GetAllMarkers(markers utils.AviObjectMarkers) []*models.RoleFilterMatchLabel
- func GetAllTenants(c *clients.AviClient, tenants map[string]struct{}, nextPage ...string) error
- func GetAnalyticsPolicyChecksum(analyticsPolicy *models.AnalyticsPolicy) uint32
- func GetAvailabilityZonesCRData(clientSet dynamic.Interface) ([]string, error)
- func GetAviMaxSupportedVersion() string
- func GetAviMinSupportedVersion() string
- func GetAviSecretWithRetry(kc kubernetes.Interface, retryCount int, secret string) (*v1.Secret, error)
- func GetCACertNodeName(infrasetting, sniHostName string) string
- func GetCNIPlugin() string
- func GetCloudMgmtNetwork() string
- func GetCloudType() string
- func GetCloudUUID() string
- func GetClusterID() string
- func GetClusterIDSplit() string
- func GetClusterLabelChecksum() uint32
- func GetClusterName() string
- func GetClusterNetworkInfoCRData(clientSet dynamic.Interface) ([]interface{}, bool)
- func GetControllerIP() string
- func GetControllerPropertiesFromSecret(cs kubernetes.Interface) (map[string]string, error)
- func GetControllerVRFContext() string
- func GetControllerVersion() string
- func GetDefaultIngController() bool
- func GetDefaultSecretForRoutes() string
- func GetDeleteConfigMap() bool
- func GetDiffPath(storedPathSvc map[string][]string, currentPathSvc map[string][]string) map[string][]string
- func GetDisableStaticRoute() bool
- func GetDomain() string
- func GetDynamicClientSet() dynamic.Interface
- func GetEnableRHI() bool
- func GetEvhNodeName(host, infrasetting string) string
- func GetEvhPGName(ingName, namespace, host, path, infrasetting string, dedicatedVs bool) string
- func GetEvhPoolName(ingName, namespace, host, path, infrasetting, svcName string, dedicatedVS bool) string
- func GetEvhPoolNameNoEncoding(ingName, namespace, host, path, infrasetting, svcName string, dedicatedVS bool) string
- func GetFqdns(vsName, key string, subDomains []string, shardSize uint32) ([]string, string)
- func GetGlobalBgpPeerLabels() []string
- func GetGlobalBlockedNSList() []string
- func GetHeaderRewritePolicy(vsName, localHost string) string
- func GetIPFamily() string
- func GetIPFromNode(node *v1.Node) (string, string)
- func GetIstioCertSet() sets.Set[string]
- func GetIstioPKIProfileName() string
- func GetIstioWorkloadCertificateName() string
- func GetK8sMaxSupportedVersion() string
- func GetK8sMinSupportedVersion() string
- func GetL4FqdnFormat() string
- func GetL4PoolName(svcName, namespace, protocol string, port int32) string
- func GetL4VSName(svcName, namespace string) string
- func GetL4VSVipName(svcName, namespace string) string
- func GetL7HttpRedirPolicy(vsName string) string
- func GetL7InsecureDSName(vsName string) string
- func GetL7PoolName(priorityLabel, namespace, ingName, infrasetting string, args ...string) string
- func GetL7SharedPGName(vsName string) string
- func GetLabelToSyncNamespace() (string, string)
- func GetLabels() []*models.KeyValue
- func GetLayer7Only() bool
- func GetMarkers() []*models.RoleFilterMatchLabel
- func GetMarkersChecksum(markers utils.AviObjectMarkers) uint32
- func GetModelName(namespace, objectName string) string
- func GetNSXTTransportZone() string
- func GetNamePrefix() string
- func GetNamespaceToSync() string
- func GetNetworkInfoCRData(clientSet dynamic.Interface) (map[string]string, map[string]string, map[string]map[string]struct{})
- func GetNoPGForSNI() bool
- func GetNodeInfraNetworkList(name string) map[string]NodeNetworkMap
- func GetNodeNetworkMap() map[string]NodeNetworkMap
- func GetNodeNetworkMapEnv() (map[string]NodeNetworkMap, error)
- func GetNodePortsSelector() map[string]string
- func GetPassthroughPGName(hostname, infrasettingName string) string
- func GetPassthroughPoolName(hostname, serviceName, infrasettingName string) string
- func GetPassthroughShardVSName(s, aviInfraSettingName, key string, shardSize uint32) string
- func GetPodCIDR(node *v1.Node) ([]string, error)
- func GetPodsFromService(namespace, serviceName string, targetPortName intstr.IntOrString) ([]utils.NamespaceName, int32)
- func GetPoolPKIProfileName(poolName string) string
- func GetPrometheusRegistry() *prometheus.Registry
- func GetResponseFromURI(client *clients.AviClient, uri string) (models.SystemConfiguration, error)
- func GetSEGName() string
- func GetSEGNameEnv() string
- func GetServiceType() string
- func GetServicesForPod(pod *corev1.Pod) ([]string, []string)
- func GetShardSizeFromAviInfraSetting(infraSetting *akov1beta1.AviInfraSetting) uint32
- func GetSniHppMapName(ingName, namespace, host, path, infrasetting string, dedicatedVS bool) string
- func GetSniHttpPolName(namespace, host, infrasetting string) string
- func GetSniNodeName(infrasetting, sniHostName string) string
- func GetSniPGName(ingName, namespace, host, path, infrasetting string, dedicatedVS bool) string
- func GetSniPoolName(ingName, namespace, host, path, infrasetting string, dedicatedVS bool, ...) string
- func GetSvcApiL4PoolName(svcName, namespace, gwName, protocol string, port int32) string
- func GetSvcKeysForNodeCRUD() (svcl4Keys []string, svcl7Keys []string)
- func GetT1LRPath() string
- func GetTLSKeyCertNodeName(infrasetting, sniHostName, secretName string) string
- func GetTenant() string
- func GetTenantFromInfraSetting(namespace, objName string) string
- func GetThrottle(key string) *uint32
- func GetVCFNetworkName() string
- func GetVCFNetworkNameWithNS(namespace string) string
- func GetVPCMode() bool
- func GetVPCs(clientSet dynamic.Interface) (map[string]string, map[string]string, error)
- func GetVipInfraNetworkList(infraName string) []akov1beta1.AviInfraSettingVipNetwork
- func GetVipNetworkList() []akov1beta1.AviInfraSettingVipNetwork
- func GetVipNetworkListEnv() ([]akov1beta1.AviInfraSettingVipNetwork, error)
- func GetVrf() string
- func GetVrfUuid() string
- func GetVsVipName(vsName string) string
- func GetshardSize() uint32
- func HasLoadBalancerIPAnnotation(svcObj *corev1.Service) bool
- func HasSharedVIPAnnotation(svcName, namespace string) bool
- func HasSpecLoadBalancerIP(svcObj *corev1.Service) bool
- func HasValidBackends(routeSpec routev1.RouteSpec, routeName, namespace, key string) bool
- func IAddrPrefixIntfToObj(ipAddrPrefixIntf map[string]interface{}) *avimodels.IPAddrPrefix
- func IPAddrIntfToObj(ipAddrIntf map[string]interface{}) *avimodels.IPAddr
- func IncrementQueueCounter(queueName string)
- func IncrementRestOpCouter(restOpMethod, objName string)
- func InformersToRegister(kclient *kubernetes.Clientset, oclient *oshiftclient.Clientset) ([]string, error)
- func IsAviLBDefaultIngressClass() (string, bool)
- func IsAviLBDefaultIngressClassWithClient() (string, bool)
- func IsChanClosed(ch <-chan struct{}) bool
- func IsClusterNameValid() (bool, error)
- func IsEvhEnabled() bool
- func IsInfraSettingNSScoped(infraSetting, namespace string) bool
- func IsIstioEnabled() bool
- func IsIstioInitialized() bool
- func IsIstioKey(key string) bool
- func IsNameEncoded(name string) bool
- func IsNamespaceBlocked(namespace string) bool
- func IsNodeNetworkAllowedCloud() bool
- func IsNodePortMode() bool
- func IsPrometheusEnabled() bool
- func IsPublicCloud() bool
- func IsSecretAviCertRef(secret string) bool
- func IsSecretK8sSecretRef(secret string) bool
- func IsServiceClusterIPType(svcObj *corev1.Service) bool
- func IsServiceNodPortType(svcObj *corev1.Service) bool
- func IsShardVS(vsName string) bool
- func IsV6EnabledCloud() bool
- func IsValidCni(returnErr *error) bool
- func IsValidLabelOnNode(labels map[string]string, key string) bool
- func IsValidV6Config(returnErr *error) bool
- func IsWCP() bool
- func L4PolicyChecksum(ports []int64, protocols []string, ingestionMarkers utils.AviObjectMarkers, ...) uint32
- func LabelsIntfToObj(labelsIntf []interface{}) []*avimodels.KeyValue
- func NewAviRestClientWithToken(api_ep, username, authToken, cadata string) *clients.AviClient
- func NewDynamicClientSet(config *rest.Config) (dynamic.Interface, error)
- func ObjectLabelChecksum(objectLabels []*models.RoleFilterMatchLabel) uint32
- func PassthroughShardSize() uint32
- func PopulateAdvL4PoolNodeMarkers(namespace, svcName, gatewayName string, port int) utils.AviObjectMarkers
- func PopulateAdvL4VSNodeMarkers(namespace, gatewayName string) utils.AviObjectMarkers
- func PopulateHTTPPolicysetNodeMarkers(namespace, host, infraSettingName string, ingName, path []string) utils.AviObjectMarkers
- func PopulateL4PolicysetMarkers(namespace, serviceName string, protocols string) utils.AviObjectMarkers
- func PopulateL4PoolNodeMarkers(namespace, svcName, port string) utils.AviObjectMarkers
- func PopulateL4VSNodeMarkers(namespace, serviceName string) utils.AviObjectMarkers
- func PopulatePGNodeMarkers(namespace, host, infraSettingName string, ingName, path []string) utils.AviObjectMarkers
- func PopulatePassthroughPGMarkers(host, infrasettingName string) utils.AviObjectMarkers
- func PopulatePassthroughPoolMarkers(host, svcName, infrasettingName string) utils.AviObjectMarkers
- func PopulatePoolNodeMarkers(namespace, host, infraSettingName, serviceName string, ingName, path []string) utils.AviObjectMarkers
- func PopulateSvcApiL4PoolNodeMarkers(namespace, svcName, gatewayName, protocol string, port int) utils.AviObjectMarkers
- func PopulateTLSKeyCertNode(host, infraSettingName string) utils.AviObjectMarkers
- func PopulateVSNodeMarkers(namespace, host, infraSettingName string) utils.AviObjectMarkers
- func RefreshAuthToken(kc kubernetes.Interface)
- func RegisterPromMetrics() *prometheus.Registry
- func RemoveGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
- func RemoveIngressFinalizer(ing *networkingv1.Ingress)
- func RemoveSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
- func RunAviInfraSettingInformer(stopCh <-chan struct{})
- func SSLKeyCertChecksum(sslName, certificate, cacert string, ingestionMarkers utils.AviObjectMarkers, ...) uint32
- func SetAKOUser(prefix string)
- func SetApiServerInstance(akoApiInstance api.ApiServerInterface)
- func SetCloudMgmtNetwork(cloudMgmtNw string)
- func SetCloudType(cloudType string)
- func SetCloudUUID(cloudUUID string)
- func SetClusterID(clusterID string)
- func SetClusterLabelChecksum()
- func SetConfigDeleteSyncChan()
- func SetControllerIP(ctrlIP string)
- func SetDeleteConfigMap(deleteCMFlag bool)
- func SetDisableSync(state bool)
- func SetDynamicClientSet(c dynamic.Interface)
- func SetIPFamily()
- func SetIsCloudInAdminTenant(isCloudInAdminTenant bool)
- func SetIstioInitialized(b bool)
- func SetLayer7Only(val string)
- func SetNSXTTransportZone(tzType string)
- func SetNamePrefix(prefix string)
- func SetNoPGForSNI(val string)
- func SetNodeInfraNetworkList(name string, nodeNetworks map[string]NodeNetworkMap)
- func SetNodeNetworkMap(nodeNetworkList map[string]NodeNetworkMap)
- func SetPrometheusRegistry()
- func SetSEGName(seg string)
- func SetStaticRouteSyncHandler()
- func SetVPCMode(vpcMode string)
- func SetVipInfraNetworkList(infraName string, vipNetworks []akov1beta1.AviInfraSettingVipNetwork)
- func SetVipNetworkList(vipNetworks []akov1beta1.AviInfraSettingVipNetwork)
- func SetVrf(vrf string)
- func SetVrfUuid(uuid string)
- func ShutdownApi()
- func StaticRoutesIntfToObj(staticRoutesIntf []interface{}) []*avimodels.StaticRoute
- func UpdateAviSecretWithRetry(kc kubernetes.Interface, aviSecret *v1.Secret, retryCount int) error
- func UpdateGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
- func UpdateIngressFinalizer(ing *networkingv1.Ingress)
- func UpdateSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
- func UpdateV6(vip *models.Vip, vipNetwork *akov1beta1.AviInfraSettingVipNetwork)
- func UseServicesAPI() bool
- func UsesNetworkRef() bool
- func VIPPerNamespace() bool
- func ValidateIngressForClass(key string, ingress *networkingv1.Ingress) bool
- func ValidateSvcforClass(key string, svc *corev1.Service) bool
- func VrfChecksum(vrfName string, staticRoutes []*models.StaticRoute) uint32
- func WaitForInitSecretRecreateAndReboot()
- type AKOCrdInformers
- type AdvL4Informers
- type BlockedNamespaces
- type BootstrapCRData
- type CRDMetadata
- type DynamicInformers
- type IstioCRDInformers
- type NPLAnnotation
- type NextPage
- type NodeNetworkMap
- type PodsWithTargetPort
- type ServiceMetadataMappingObjType
- type ServiceMetadataObj
- type ServicesAPIInformers
- type VSNameMetadata
Constants ¶
const ( DISABLE_STATIC_ROUTE_SYNC = "DISABLE_STATIC_ROUTE_SYNC" ENABLE_RHI = "ENABLE_RHI" ENABLE_EVH = "ENABLE_EVH" CNI_PLUGIN = "CNI_PLUGIN" CALICO_CNI = "calico" ANTREA_CNI = "antrea" NCP_CNI = "ncp" OPENSHIFT_CNI = "openshift" OVN_KUBERNETES_CNI = "ovn-kubernetes" CILIUM_CNI = "cilium" INGRESS_API = "INGRESS_API" AviConfigMap = "avi-k8s-config" AviSecret = "avi-secret" AviInitSecret = "avi-init-secret" VLAN_TRANSPORT_ZONE = "VLAN" OVERLAY_TRANSPORT_ZONE = "OVERLAY" IP_FAMILY = "IP_FAMILY" AVI_INGRESS_CLASS = "avi" NETWORK_NAME = "NETWORK_NAME" VIP_NETWORK_LIST = "VIP_NETWORK_LIST" BGP_PEER_LABELS = "BGP_PEER_LABELS" SEG_NAME = "SEG_NAME" BLOCKED_NS_LIST = "BLOCKED_NS_LIST" DEFAULT_SE_GROUP = "Default-Group" NODE_NETWORK_LIST = "NODE_NETWORK_LIST" NODE_NETWORK_MAX_ENTRIES = 5 DEFAULT_DOMAIN = "DEFAULT_DOMAIN" ADVANCED_L4 = "ADVANCED_L4" SERVICES_API = "SERVICES_API" CLUSTER_NAME = "CLUSTER_NAME" CLUSTER_ID = "CLUSTER_ID" CLOUD_VCENTER = "CLOUD_VCENTER" CLOUD_AZURE = "CLOUD_AZURE" CLOUD_AWS = "CLOUD_AWS" CLOUD_OPENSTACK = "CLOUD_OPENSTACK" CLOUD_GCP = "CLOUD_GCP" CLOUD_NONE = "CLOUD_NONE" CLOUD_NSXT = "CLOUD_NSXT" DEFAULT_SHARD_SCHEME = "hostname" HOSTNAME_SHARD_SCHEME = "hostname" NAMESPACE_SHARD_SCHEME = "namespace" SLOW_RETRY_LAYER = "SlowRetryLayer" FAST_RETRY_LAYER = "FastRetryLayer" NOT_FOUND = "HTTP code: 404" STATUS_REDIRECT = "HTTP_REDIRECT_STATUS_CODE_302" CLOSE_CONNECTION = "HTTP_SECURITY_ACTION_CLOSE_CONN" IS_IN = "IS_IN" SLOW_SYNC_TIME = 90 // seconds LOG_LEVEL = "logLevel" EnableEvents = "enableEvents" LAYER7_ONLY = "layer7Only" NO_PG_FOR_SNI = "noPGForSNI" SERVICE_TYPE = "SERVICE_TYPE" NODE_PORT = "NodePort" NODE_KEY = "NODE_KEY" NODE_VALUE = "NODE_VALUE" ShardVSSubstring = "Shared-" ShardVSPrefix = "Shared-L7" ShardEVHVSPrefix = "Shared-L7-EVH-" AKOPrefix = "ako-" DedicatedSuffix = "-L7-dedicated" EVHSuffix = "-EVH" PassthroughPrefix = "Shared-Passthrough-" PolicyAllow = "ALLOW" PolicyNone = "NONE" PolicyEdgeTerm = "EDGE" PolicyRedirect = "REDIRECT" PolicyPass = "PASSTHROUGH" DeleteConfig = "deleteConfig" NodePort = "NodePort" NodePortLocal = "NodePortLocal" RouteSecretsPrefix = "-route-secret" CertTypeVS = "SSL_CERTIFICATE_TYPE_VIRTUALSERVICE" CertTypeCA = "SSL_CERTIFICATE_TYPE_CA" HostRule = "HostRule" HTTPRule = "HTTPRule" AviInfraSetting = "AviInfraSetting" SSORule = "SSORule" L4Rule = "L4Rule" L7Rule = "L7Rule" IstioVirtualService = "IstioVirtualService" IstioDestinationRule = "DestinationRule" IstioGateway = "IstioGateway" MultiClusterIngress = "MultiClusterIngress" ServiceImport = "ServiceImport" DummySecret = "@avisslkeycertrefdummy" DummySecretK8s = "@k8ssecretdummy" StatusRejected = "Rejected" StatusAccepted = "Accepted" AllowedL7ApplicationProfile = "APPLICATION_PROFILE_TYPE_HTTP" AllowedL4ApplicationProfile = "APPLICATION_PROFILE_TYPE_L4" AllowedL4SSLApplicationProfile = "APPLICATION_PROFILE_TYPE_SSL" AllowedTCPProxyNetworkProfileType = "PROTOCOL_TYPE_TCP_PROXY" TypeTLSReencrypt = "reencrypt" DefaultPoolSSLProfile = "System-Standard" LB_ALGORITHM_CONSISTENT_HASH_CUSTOM_HEADER = "LB_ALGORITHM_CONSISTENT_HASH_CUSTOM_HEADER" LB_ALGORITHM_CONSISTENT_HASH = "LB_ALGORITHM_CONSISTENT_HASH" Gateway = "Gateway" GatewayClass = "GatewayClass" HTTPRoute = "HTTPRoute" DuplicateBackends = "MultipleBackendsWithSameServiceError" DummyVSForStaleData = "DummyVSForStaleData" ControllerReqWaitTime = 300 PassthroughInsecure = "-insecure" AviControllerVSVipIDChangeError = "Changing an existing VIP's vip_id is not supported" AviControllerRecreateVIPError = "If a new preferred IP is needed, please recreate the VIP" ClusterStatusCacheKey = "cluster-runtime" AviObjDeletionTime = 30 // Minutes AKOStatefulSet = "ako" ObjectDeletionStartStatus = "Started" ObjectDeletionDoneStatus = "Done" ObjectDeletionTimeoutStatus = "Timeout" DefaultRouteCert = "router-certs-default" ClusterNameLabelKey = "clustername" UpdateStatus = "UpdateStatus" DeleteStatus = "DeleteStatus" NPLService = "NPLService" SyncStatusKey = "syncstatus" NoFreeIPError = "No available free IPs" ConfigDisallowedDuringUpgradeError = "Configuration is disallowed during upgrade" VSVIPNotFoundError = "VsVip object not found" DataScript = "Vsdatascript" EVHVS = "EVH VirtualService" HTTPPS = "HTTPPolicySet" HPPMAP = "HTTP Policyset Map" HTTPSecurityRule = "HTTP Security Rule" HTTPRequestRule = "HTTP Request Rule" HTTPRedirectRule = "HTTP Redirect Rule" HTTPRewriteRule = "HTTP Header Rewrite Rule" HTTPRedirectPolicy = "HTTP Redirect Policy" HeaderRewritePolicy = "Header Rewrite Policy" L4VS = "L4 Virtual Service" L4VIP = "L4 VIP" L4Pool = "L4 Pool" L4AdvPool = "L4 Advance Pool" L4PS = "L4 Policyset" L4PSRule = "L4 Policyset Rule" SNIVS = "SNI VirtualService" VIP = "VS VIP" PG = "Poolgroup" PriorityLabel = "PriorityLabel" SSLKeyCert = "SSLKeyandCertificate" PKIProfile = "PKI Profile" PassthroughPG = "Passthrough PG" Passthroughpool = "Passthrough pool" PassthroughVS = "Passthrough VirtualService" Pool = "Pool" TLSKeyCert = "TLS KeyCert" CACert = "CA Cert" IPCIDRRegex = `^(\b([01]?[0-9][0-9]?|2[0-4][0-9]|25[0-5])\.){3}([01]?[0-9][0-9]?|2[0-4][0-9]|25[0-5])\/(([0-9]|[1-2][0-9]|3[0-2]))?$` IPRegex = `\b(([01]?[0-9][0-9]?|2[0-4][0-9]|25[0-5])(\.|$)){4}\b` IPV6CIDRRegex = `` /* 196-byte string literal not displayed */ AutoFQDNDefault = "Default" AutoFQDNFlat = "Flat" AutoFQDNDisabled = "Disabled" FQDN_SVCNAME_PREFIX = "s" FQDN_SVCNAMESPACE_PREFIX = "n" FQDN_SUBDOMAIN_PREFIX = "d" DNS_LABEL_LENGTH = 63 VCF_NETWORK = "vcf-ako-net" VIP_PER_NAMESPACE = "VIP_PER_NAMESPACE" PRIMARY_AKO_FLAG = "PRIMARY_AKO_FLAG" CRDActive = "ACTIVE" CRDInactive = "INACTIVE" SSLPort = 443 IPAMProviderInfoblox = "IPAMDNS_TYPE_INFOBLOX" IPAMProviderCustom = "IPAMDNS_TYPE_CUSTOM" HttpRulePkiAndDestCASetErr = "PKIProfile and DestinationCA fields are set in the HTTPRule. Only one of the field should be set." IPTypeV4Only = "V4_ONLY" IPTypeV6Only = "V6_ONLY" IPTypeV4V6 = "V4_V6" IstioCertOutputPath = "/etc/istio-output-certs" IstioSecret = "istio-secret" IstioModel = "istioModel" CTRL_VERSION_21_1_3 = "21.1.3" FullSyncInterval = 300 Namespace = "Namespace" VrfContextNotFoundError = "VrfContext not found" HTTPMethodGet = "GET" HTTPMethodPut = "PUT" VrfContextObjectNotFoundError = "VrfContext object not found" NetworkNotFoundError = "Network object not found" // AKO Event constants AKOEventComponent = "avi-kubernetes-operator" AKOShutdown = "AKOShutdown" SyncDisabled = "SyncDisabled" ValidatedUserInput = "ValidatedUserInput" StatusSync = "StatusSync" AKOReady = "AKOReady" AKOPause = "AKOPause" DuplicateHostPath = "DuplicateHostPath" DuplicateHost = "DuplicateHost" Removed = "Removed" Synced = "Synced" Attached = "Attached" Detached = "Detached" InvalidConfiguration = "InvalidConfiguration" AKODeleteConfigSet = "AKODeleteConfigSet" AKODeleteConfigUnset = "AKODeleteConfigUnset" AKODeleteConfigDone = "AKODeleteConfigDone" AKODeleteConfigTimeout = "AKODeleteConfigTimeout" AKOGatewayEventComponent = "avi-kubernetes-operator-gateway-api" DefaultIngressClassAnnotation = "ingressclass.kubernetes.io/is-default-class" ExternalDNSAnnotation = "external-dns.alpha.kubernetes.io/hostname" GatewayFinalizer = "gateway.ako.vmware.com" IngressFinalizer = "ingress.ako.vmware.com/finalizer" AkoGroup = "ako.vmware.com" AviIngressController = "ako.vmware.com/avi-lb" AKOConditionType = "ako.vmware.com/ObjectDeletionInProgress" DefaultSecretEnabled = "ako.vmware.com/enable-tls" GatewayNameLabelKey = "service.route.lbapi.run.tanzu.vmware.com/gateway-name" GatewayNamespaceLabelKey = "service.route.lbapi.run.tanzu.vmware.com/gateway-namespace" GatewayTypeLabelKey = "service.route.lbapi.run.tanzu.vmware.com/type" AviGatewayController = "lbapi.run.tanzu.vmware.com/avi-lb" SvcApiGatewayNameLabelKey = "ako.vmware.com/gateway-name" SvcApiGatewayNamespaceLabelKey = "ako.vmware.com/gateway-namespace" SvcApiAviGatewayController = "ako.vmware.com/avi-lb" NPLPodAnnotation = "nodeportlocal.antrea.io" NPLSvcAnnotation = "nodeportlocal.antrea.io/enabled" InfraSettingNameAnnotation = "aviinfrasetting.ako.vmware.com/name" SkipNodePortAnnotation = "skipnodeport.ako.vmware.com/enabled" PassthroughAnnotation = "passthrough.ako.vmware.com/enabled" StaticRouteAnnotation = "ako.vmware.com/pod-cidrs" OVNNodeSubnetAnnotation = "k8s.ovn.org/node-subnets" WCPSEGroup = "ako.vmware.com/wcp-se-group" WCPCloud = "ako.vmware.com/wcp-cloud-name" VSAnnotation = "ako.vmware.com/host-fqdn-vs-uuid-map" ControllerAnnotation = "ako.vmware.com/controller-cluster-uuid" LoadBalancerIP = "ako.vmware.com/load-balancer-ip" LBSvcAppProfileAnnotation = "ako.vmware.com/application-profile" L4RuleAnnotation = "ako.vmware.com/l4rule" // Specifies command used in namespace event handler NsFilterAdd = "ADD" NsFilterDelete = "DELETE" PoolNameSuffixForHttpPolToPool = "policy-to-pool" AVI_OBJ_NAME_MAX_LENGTH = 255 ACCESS_TOKEN_TYPE_JWT = "ACCESS_TOKEN_TYPE_JWT" ACCESS_TOKEN_TYPE_OPAQUE = "ACCESS_TOKEN_TYPE_OPAQUE" SAML_AUTHN_REQ_ACS_TYPE_INDEX = "SAML_AUTHN_REQ_ACS_TYPE_INDEX" // License types LicenseTypeEnterprise = "ENTERPRISE" )
const ( // AviSettingGWClassIndex maintains a map of AviInfraSetting Name to // GatewayClass Objects. This helps in fetching all GatewayClasses with a // given AviinfraSetting Name. AviSettingGWClassIndex = "aviSettingGWClass" // GatewayClassGatewayIndex maintains a map of GatewayClass Name to // Gateway Objects. This helps in fetching all Gateways with a // given GatewayClass Name. GatewayClassGatewayIndex = "gatewayClassGateway" // SeGroupAviSettingIndex maintains a map of SeGroup Name to // AviInfraSetting Objects. This helps in fetching all AviInfraSettings // with a given SeGroup Name. SeGroupAviSettingIndex = "seGroupAviSetting" // AviSettingServicesIndex maintains a map of AviInfraSetting Objects to // Service Namespace/Name. This helps in fettching all Services // with a given AviInfraSetting. AviSettingServicesIndex = "aviSettingServices" // AviSettingIngClassIndex maintains a map of AviInfraSetting Name to // IngressClass Objects. This helps in fetching all IngressClasses with a // given AviinfraSetting Name. AviSettingIngClassIndex = "aviSettingIngClass" // v maintains a map of AviInfraSetting Name to // Route Objects. This helps in fetching all Routes with a // given AviinfraSetting Name. AviSettingRouteIndex = "aviSettingRoute" // L4RuleToServicesIndex maintains a map of L4Rule CRD to // Service objects. This helps in fetching all Services // with a given L4Rule CRD name. L4RuleToServicesIndex = "l4RuleToServicesIndex" // AviSettingNamespaceIndex maintains a map of AviInfraSetting Objects to // Namespace objects. This helps in fettching a Namespace with a given // AviInfraSetting. AviSettingNamespaceIndex = "aviSettingNamespaces" )
Cache Indexer constants.
const (
PassthroughDatascript = `` /* 591-byte string literal not displayed */
)
Passthrough deployment same in EVH and SNI. Not changing log messages.
Variables ¶
var ( // CalicoBlockaffinityGVR : Calico's BlockAffinity CRD resource identifier CalicoBlockaffinityGVR = schema.GroupVersionResource{ Group: "crd.projectcalico.org", Version: "v1", Resource: "blockaffinities", } // HostSubnetGVR : OpenShift's HostSubnet CRD resource identifier HostSubnetGVR = schema.GroupVersionResource{ Group: "network.openshift.io", Version: "v1", Resource: "hostsubnets", } // CiliumNodeGVR : Cilium's CiliumNode CRD resource identifier CiliumNodeGVR = schema.GroupVersionResource{ Group: "cilium.io", Version: "v2", Resource: "ciliumnodes", } NetworkInfoGVR = schema.GroupVersionResource{ Group: "nsx.vmware.com", Version: "v1alpha1", Resource: "namespacenetworkinfos", } ClusterNetworkGVR = schema.GroupVersionResource{ Group: "nsx.vmware.com", Version: "v1alpha1", Resource: "clusternetworkinfos", } AvailabilityZoneVR = schema.GroupVersionResource{ Group: "topology.tanzu.vmware.com", Version: "v1alpha1", Resource: "availabilityzones", } VPCGVR = schema.GroupVersionResource{ Group: "nsx.vmware.com", Version: "v1alpha1", Resource: "vpcs", } )
var AKOUser string
var AviSEInitialized bool
var AviSecretInitialized bool
var CloudMgmtNetwork string
var CloudType string
var CloudUUID string
var ClusterID string
var ConfigDeleteSyncChan chan struct{}
var DisableSync bool
var IPfamily string
var IsCloudInAdminTenant = true
var NamePrefix string
var NodeInfraNetworkList map[string]map[string]NodeNetworkMap
var NodeNetworkList map[string]NodeNetworkMap
var NsxTTzType string
var ObjectsInQueue *prometheus.GaugeVec
var RestOpPerKeyType *prometheus.CounterVec
var SEGroupName string
var ShardSchemeMap = map[string]string{
"hostname": "hostname",
"namespace": "namespace",
}
var ShardSizeMap = map[string]uint32{
"LARGE": 8,
"MEDIUM": 4,
"SMALL": 1,
"DEDICATED": 0,
}
var StaticRouteSyncChan chan struct{}
var TotalRestOp prometheus.Counter
var VCFInitialized bool
var VPCMode bool
var VRFContext string
var VRFUuid string
var VipInfraNetworkList map[string][]akov1beta1.AviInfraSettingVipNetwork
var VipNetworkList []akov1beta1.AviInfraSettingVipNetwork
Functions ¶
func AKOControlConfig ¶
func AKOControlConfig() *akoControlConfig
func AnnotateSystemNamespaceWithInfraSetting ¶
func AnnotateSystemNamespaceWithInfraSetting()
func AutoAnnotateNPLSvc ¶
func AutoAnnotateNPLSvc() bool
AutoAnnotateNPLSvc returns true if AKO is automatically annotating required Services instead of user for NPL
func AviGetCollectionRaw ¶
func CheckAndSetGatewayFinalizer ¶
func CheckAndSetGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
func CheckAndSetIngressFinalizer ¶
func CheckAndSetIngressFinalizer(ing *networkingv1.Ingress)
func CheckAndSetSvcApiGatewayFinalizer ¶
func CheckAndSetSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
func CheckConstraintsForRFC ¶
func CheckObjectNameLength ¶
func CheckRFC1035 ¶
func CompareVersions ¶
CompareVersions compares version v1 against version v2.
func CreateAviInfraSetting ¶
func CreateAviInfraSetting(name, network, t1lr, project string) (*akov1beta1.AviInfraSetting, error)
func CreateIstioSecretFromCert ¶
func CreateIstioSecretFromCert(name string, kc kubernetes.Interface)
func DSChecksum ¶
func DSChecksum(pgrefs []string, markers []*models.RoleFilterMatchLabel, populateCache bool) uint32
func DecrementQueueCounter ¶
func DecrementQueueCounter(queueName string)
func Difference ¶
Difference compares two slices a & b, returns the elements in `a` that aren't in `b`.
func GetAKOIDPrefix ¶
func GetAKOIDPrefix() string
func GetAKOUser ¶
func GetAKOUser() string
func GetAdminTenant ¶
func GetAdminTenant() string
func GetAdvL4PoolName ¶
func GetAdvancedL4 ¶
func GetAdvancedL4() bool
This utility returns a true/false depending on whether the user requires advanced L4 functionality
func GetAllMarkers ¶
func GetAllMarkers(markers utils.AviObjectMarkers) []*models.RoleFilterMatchLabel
GetMarkers returns the key values pair used for tagging the segroups and routes in vrfcontext
func GetAllTenants ¶
func GetAnalyticsPolicyChecksum ¶
func GetAnalyticsPolicyChecksum(analyticsPolicy *models.AnalyticsPolicy) uint32
func GetAviMaxSupportedVersion ¶
func GetAviMaxSupportedVersion() string
func GetAviMinSupportedVersion ¶
func GetAviMinSupportedVersion() string
func GetAviSecretWithRetry ¶
func GetCACertNodeName ¶
func GetCNIPlugin ¶
func GetCNIPlugin() string
GetCNIPlugin returns the user provided CNI plugin - oneof (calico|canal|flannel)
func GetCloudMgmtNetwork ¶
func GetCloudMgmtNetwork() string
func GetCloudType ¶
func GetCloudType() string
func GetCloudUUID ¶
func GetCloudUUID() string
func GetClusterID ¶
func GetClusterID() string
func GetClusterIDSplit ¶
func GetClusterIDSplit() string
func GetClusterLabelChecksum ¶
func GetClusterLabelChecksum() uint32
func GetClusterName ¶
func GetClusterName() string
func GetControllerIP ¶
func GetControllerIP() string
func GetControllerPropertiesFromSecret ¶
func GetControllerPropertiesFromSecret(cs kubernetes.Interface) (map[string]string, error)
func GetControllerVersion ¶
func GetControllerVersion() string
func GetDefaultIngController ¶
func GetDefaultIngController() bool
func GetDefaultSecretForRoutes ¶
func GetDefaultSecretForRoutes() string
func GetDeleteConfigMap ¶
func GetDeleteConfigMap() bool
func GetDiffPath ¶
func GetDisableStaticRoute ¶
func GetDisableStaticRoute() bool
func GetDynamicClientSet ¶
GetDynamicClientSet returns dynamic client set instance
func GetEnableRHI ¶
func GetEnableRHI() bool
func GetEvhNodeName ¶
func GetEvhPGName ¶
func GetEvhPoolName ¶
func GetEvhPoolName(ingName, namespace, host, path, infrasetting, svcName string, dedicatedVS bool) string
evh child
func GetGlobalBgpPeerLabels ¶
func GetGlobalBgpPeerLabels() []string
func GetGlobalBlockedNSList ¶
func GetGlobalBlockedNSList() []string
func GetHeaderRewritePolicy ¶
func GetIPFamily ¶
func GetIPFamily() string
func GetIstioCertSet ¶
func GetIstioPKIProfileName ¶
func GetIstioPKIProfileName() string
func GetIstioWorkloadCertificateName ¶
func GetIstioWorkloadCertificateName() string
func GetK8sMaxSupportedVersion ¶
func GetK8sMaxSupportedVersion() string
func GetK8sMinSupportedVersion ¶
func GetK8sMinSupportedVersion() string
func GetL4FqdnFormat ¶
func GetL4FqdnFormat() string
func GetL4PoolName ¶
func GetL4VSVipName ¶
func GetL7HttpRedirPolicy ¶
func GetL7InsecureDSName ¶
func GetL7PoolName ¶
func GetL7SharedPGName ¶
func GetLabelToSyncNamespace ¶
func GetLabels ¶
GetLabels returns the key value pair used for tagging the segroups and routes in vrfcontext
func GetLayer7Only ¶
func GetLayer7Only() bool
func GetMarkers ¶
func GetMarkers() []*models.RoleFilterMatchLabel
func GetMarkersChecksum ¶
func GetMarkersChecksum(markers utils.AviObjectMarkers) uint32
func GetModelName ¶
func GetNSXTTransportZone ¶
func GetNSXTTransportZone() string
func GetNamePrefix ¶
func GetNamePrefix() string
func GetNamespaceToSync ¶
func GetNamespaceToSync() string
func GetNetworkInfoCRData ¶
func GetNoPGForSNI ¶
func GetNoPGForSNI() bool
func GetNodeInfraNetworkList ¶
func GetNodeInfraNetworkList(name string) map[string]NodeNetworkMap
func GetNodeNetworkMap ¶
func GetNodeNetworkMap() map[string]NodeNetworkMap
func GetNodeNetworkMapEnv ¶
func GetNodeNetworkMapEnv() (map[string]NodeNetworkMap, error)
func GetNodePortsSelector ¶
func GetPassthroughPGName ¶
func GetPassthroughPoolName ¶
func GetPodCIDR ¶
GetPodCIDR returns the node's configured PodCIDR
func GetPodsFromService ¶
func GetPodsFromService(namespace, serviceName string, targetPortName intstr.IntOrString) ([]utils.NamespaceName, int32)
func GetPoolPKIProfileName ¶
func GetPrometheusRegistry ¶
func GetPrometheusRegistry() *prometheus.Registry
func GetResponseFromURI ¶
func GetSEGName ¶
func GetSEGName() string
func GetSEGNameEnv ¶
func GetSEGNameEnv() string
func GetServiceType ¶
func GetServiceType() string
ToDo: Set the Service Type only once. But this creates a problem in UTs, because different types of Services needs to be tested in the UTs.
func GetShardSizeFromAviInfraSetting ¶
func GetShardSizeFromAviInfraSetting(infraSetting *akov1beta1.AviInfraSetting) uint32
func GetSniHppMapName ¶
func GetSniHttpPolName ¶
func GetSniNodeName ¶
func GetSniPGName ¶
func GetSniPoolName ¶
func GetSvcApiL4PoolName ¶
func GetSvcKeysForNodeCRUD ¶
func GetT1LRPath ¶
func GetT1LRPath() string
func GetTLSKeyCertNodeName ¶
func GetThrottle ¶
func GetVCFNetworkName ¶
func GetVCFNetworkName() string
func GetVCFNetworkNameWithNS ¶
func GetVPCMode ¶
func GetVPCMode() bool
func GetVipInfraNetworkList ¶
func GetVipInfraNetworkList(infraName string) []akov1beta1.AviInfraSettingVipNetwork
func GetVipNetworkList ¶
func GetVipNetworkList() []akov1beta1.AviInfraSettingVipNetwork
func GetVipNetworkListEnv ¶
func GetVipNetworkListEnv() ([]akov1beta1.AviInfraSettingVipNetwork, error)
func GetVrfUuid ¶
func GetVrfUuid() string
func GetshardSize ¶
func GetshardSize() uint32
func HasSharedVIPAnnotation ¶
func HasSpecLoadBalancerIP ¶
func HasValidBackends ¶
func IAddrPrefixIntfToObj ¶
func IAddrPrefixIntfToObj(ipAddrPrefixIntf map[string]interface{}) *avimodels.IPAddrPrefix
func IPAddrIntfToObj ¶
func IncrementQueueCounter ¶
func IncrementQueueCounter(queueName string)
func IncrementRestOpCouter ¶
func IncrementRestOpCouter(restOpMethod, objName string)
func InformersToRegister ¶
func InformersToRegister(kclient *kubernetes.Clientset, oclient *oshiftclient.Clientset) ([]string, error)
func IsChanClosed ¶
func IsChanClosed(ch <-chan struct{}) bool
func IsClusterNameValid ¶
func IsEvhEnabled ¶
func IsEvhEnabled() bool
This utility returns true if AKO is configured to create VS with Enhanced Virtual Hosting
func IsInfraSettingNSScoped ¶
Do not use Avi Infra Setting in Avi object names if it's annotated to a namespace
func IsIstioEnabled ¶
func IsIstioEnabled() bool
func IsIstioInitialized ¶
func IsIstioInitialized() bool
func IsIstioKey ¶
func IsNameEncoded ¶
func IsNodeNetworkAllowedCloud ¶
func IsNodeNetworkAllowedCloud() bool
func IsNodePortMode ¶
func IsNodePortMode() bool
func IsPrometheusEnabled ¶
func IsPrometheusEnabled() bool
TODO: Can be optimized by setting up variable at bootup and then do GET for that instead of fetching each time.
func IsPublicCloud ¶
func IsPublicCloud() bool
func IsSecretAviCertRef ¶
func IsSecretK8sSecretRef ¶
func IsServiceClusterIPType ¶
func IsServiceNodPortType ¶
func IsV6EnabledCloud ¶
func IsV6EnabledCloud() bool
func IsValidCni ¶
func IsValidV6Config ¶
func IsWCP ¶
func IsWCP() bool
Wrapper function for AKO running in either VDS or VCF (WCP with NSX).
func L4PolicyChecksum ¶
func L4PolicyChecksum(ports []int64, protocols []string, ingestionMarkers utils.AviObjectMarkers, markers []*models.RoleFilterMatchLabel, populateCache bool) uint32
func LabelsIntfToObj ¶
func NewDynamicClientSet ¶
NewDynamicClientSet initializes dynamic client set instance
func ObjectLabelChecksum ¶
func ObjectLabelChecksum(objectLabels []*models.RoleFilterMatchLabel) uint32
func PassthroughShardSize ¶
func PassthroughShardSize() uint32
func PopulateAdvL4PoolNodeMarkers ¶
func PopulateAdvL4PoolNodeMarkers(namespace, svcName, gatewayName string, port int) utils.AviObjectMarkers
func PopulateAdvL4VSNodeMarkers ¶
func PopulateAdvL4VSNodeMarkers(namespace, gatewayName string) utils.AviObjectMarkers
func PopulateHTTPPolicysetNodeMarkers ¶
func PopulateHTTPPolicysetNodeMarkers(namespace, host, infraSettingName string, ingName, path []string) utils.AviObjectMarkers
func PopulateL4PolicysetMarkers ¶
func PopulateL4PolicysetMarkers(namespace, serviceName string, protocols string) utils.AviObjectMarkers
func PopulateL4PoolNodeMarkers ¶
func PopulateL4PoolNodeMarkers(namespace, svcName, port string) utils.AviObjectMarkers
func PopulateL4VSNodeMarkers ¶
func PopulateL4VSNodeMarkers(namespace, serviceName string) utils.AviObjectMarkers
func PopulatePGNodeMarkers ¶
func PopulatePGNodeMarkers(namespace, host, infraSettingName string, ingName, path []string) utils.AviObjectMarkers
func PopulatePassthroughPGMarkers ¶
func PopulatePassthroughPGMarkers(host, infrasettingName string) utils.AviObjectMarkers
func PopulatePassthroughPoolMarkers ¶
func PopulatePassthroughPoolMarkers(host, svcName, infrasettingName string) utils.AviObjectMarkers
func PopulatePoolNodeMarkers ¶
func PopulatePoolNodeMarkers(namespace, host, infraSettingName, serviceName string, ingName, path []string) utils.AviObjectMarkers
func PopulateSvcApiL4PoolNodeMarkers ¶
func PopulateSvcApiL4PoolNodeMarkers(namespace, svcName, gatewayName, protocol string, port int) utils.AviObjectMarkers
func PopulateTLSKeyCertNode ¶
func PopulateTLSKeyCertNode(host, infraSettingName string) utils.AviObjectMarkers
func PopulateVSNodeMarkers ¶
func PopulateVSNodeMarkers(namespace, host, infraSettingName string) utils.AviObjectMarkers
func RefreshAuthToken ¶
func RefreshAuthToken(kc kubernetes.Interface)
func RegisterPromMetrics ¶
func RegisterPromMetrics() *prometheus.Registry
func RemoveGatewayFinalizer ¶
func RemoveGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
Utility functions to add/remove finalizers on AdvancedL4 Gateways synced by AKO.
func RemoveIngressFinalizer ¶
func RemoveIngressFinalizer(ing *networkingv1.Ingress)
Utility functions to add/remove finalizers on Ingresses synced by AKO.
func RemoveSvcApiGatewayFinalizer ¶
func RemoveSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
Utility functions to add/remove finalizers on Gateways synced by AKO.
func RunAviInfraSettingInformer ¶
func RunAviInfraSettingInformer(stopCh <-chan struct{})
func SSLKeyCertChecksum ¶
func SSLKeyCertChecksum(sslName, certificate, cacert string, ingestionMarkers utils.AviObjectMarkers, markers []*models.RoleFilterMatchLabel, populateCache bool) uint32
func SetAKOUser ¶
func SetAKOUser(prefix string)
func SetApiServerInstance ¶
func SetApiServerInstance(akoApiInstance api.ApiServerInterface)
func SetCloudMgmtNetwork ¶
func SetCloudMgmtNetwork(cloudMgmtNw string)
func SetCloudType ¶
func SetCloudType(cloudType string)
func SetCloudUUID ¶
func SetCloudUUID(cloudUUID string)
func SetClusterID ¶
func SetClusterID(clusterID string)
func SetClusterLabelChecksum ¶
func SetClusterLabelChecksum()
func SetConfigDeleteSyncChan ¶
func SetConfigDeleteSyncChan()
func SetControllerIP ¶
func SetControllerIP(ctrlIP string)
func SetDeleteConfigMap ¶
func SetDeleteConfigMap(deleteCMFlag bool)
func SetDisableSync ¶
func SetDisableSync(state bool)
func SetDynamicClientSet ¶
SetDynamicClientSet is used for Unit tests.
func SetIPFamily ¶
func SetIPFamily()
func SetIsCloudInAdminTenant ¶
func SetIsCloudInAdminTenant(isCloudInAdminTenant bool)
func SetIstioInitialized ¶
func SetIstioInitialized(b bool)
func SetLayer7Only ¶
func SetLayer7Only(val string)
func SetNSXTTransportZone ¶
func SetNSXTTransportZone(tzType string)
func SetNamePrefix ¶
func SetNamePrefix(prefix string)
func SetNoPGForSNI ¶
func SetNoPGForSNI(val string)
func SetNodeInfraNetworkList ¶
func SetNodeInfraNetworkList(name string, nodeNetworks map[string]NodeNetworkMap)
func SetNodeNetworkMap ¶
func SetNodeNetworkMap(nodeNetworkList map[string]NodeNetworkMap)
func SetPrometheusRegistry ¶
func SetPrometheusRegistry()
func SetSEGName ¶
func SetSEGName(seg string)
func SetStaticRouteSyncHandler ¶
func SetStaticRouteSyncHandler()
func SetVPCMode ¶
func SetVPCMode(vpcMode string)
func SetVipInfraNetworkList ¶
func SetVipInfraNetworkList(infraName string, vipNetworks []akov1beta1.AviInfraSettingVipNetwork)
func SetVipNetworkList ¶
func SetVipNetworkList(vipNetworks []akov1beta1.AviInfraSettingVipNetwork)
func SetVrfUuid ¶
func SetVrfUuid(uuid string)
func ShutdownApi ¶
func ShutdownApi()
func StaticRoutesIntfToObj ¶
func StaticRoutesIntfToObj(staticRoutesIntf []interface{}) []*avimodels.StaticRoute
func UpdateGatewayFinalizer ¶
func UpdateGatewayFinalizer(gw *advl4v1alpha1pre1.Gateway)
func UpdateIngressFinalizer ¶
func UpdateIngressFinalizer(ing *networkingv1.Ingress)
func UpdateSvcApiGatewayFinalizer ¶
func UpdateSvcApiGatewayFinalizer(gw *svcapiv1alpha1.Gateway)
func UpdateV6 ¶
func UpdateV6(vip *models.Vip, vipNetwork *akov1beta1.AviInfraSettingVipNetwork)
func UseServicesAPI ¶
func UseServicesAPI() bool
If this flag is set to true, then AKO uses services API. Currently the support is limited for layer 4 Virtualservices
func UsesNetworkRef ¶
func UsesNetworkRef() bool
func VIPPerNamespace ¶
func VIPPerNamespace() bool
func ValidateIngressForClass ¶
func ValidateIngressForClass(key string, ingress *networkingv1.Ingress) bool
func VrfChecksum ¶
func VrfChecksum(vrfName string, staticRoutes []*models.StaticRoute) uint32
func WaitForInitSecretRecreateAndReboot ¶
func WaitForInitSecretRecreateAndReboot()
WaitForInitSecretRecreateAndReboot Deletes the avi-init-secret provided by NCP, in order for NCP to generate the token and recreate the Secret. After Secret deletion, once AKO finds a new Secret created, it reboots in order to refresh the Client and Session to the Avi Controller. This can be further improved to update Avi Controller Session during runtime, but is complicated business right now.
Types ¶
type AKOCrdInformers ¶
type AKOCrdInformers struct { HostRuleInformer v1beta1akoinformer.HostRuleInformer HTTPRuleInformer v1beta1akoinformer.HTTPRuleInformer AviInfraSettingInformer v1beta1akoinformer.AviInfraSettingInformer SSORuleInformer v1alpha2akoinformer.SSORuleInformer L4RuleInformer v1alpha2akoinformer.L4RuleInformer L7RuleInformer v1alpha2akoinformer.L7RuleInformer }
type AdvL4Informers ¶
type AdvL4Informers struct { GatewayInformer advl4informer.GatewayInformer GatewayClassInformer advl4informer.GatewayClassInformer }
type BlockedNamespaces ¶
type BlockedNamespaces struct { BlockedNSMap map[string]struct{} // contains filtered or unexported fields }
type BootstrapCRData ¶
type BootstrapCRData struct {
SecretName, SecretNamespace, UserName, TZPath, AviURL string
}
type CRDMetadata ¶
type DynamicInformers ¶
type DynamicInformers struct { CalicoBlockAffinityInformer informers.GenericInformer HostSubnetInformer informers.GenericInformer CiliumNodeInformer informers.GenericInformer VCFNetworkInfoInformer informers.GenericInformer VCFClusterNetworkInformer informers.GenericInformer AvailabilityZoneInformer informers.GenericInformer VPCInformer informers.GenericInformer }
DynamicInformers holds third party generic informers
func GetDynamicInformers ¶
func GetDynamicInformers() *DynamicInformers
GetDynamicInformers returns DynamicInformers instance
func NewDynamicInformers ¶
func NewDynamicInformers(client dynamic.Interface, akoInfra bool) *DynamicInformers
NewDynamicInformers initializes the DynamicInformers struct
type IstioCRDInformers ¶
type IstioCRDInformers struct { VirtualServiceInformer istioInformer.VirtualServiceInformer DestinationRuleInformer istioInformer.DestinationRuleInformer GatewayInformer istioInformer.GatewayInformer }
type NPLAnnotation ¶
type NodeNetworkMap ¶
type PodsWithTargetPort ¶
type PodsWithTargetPort struct { Pods []utils.NamespaceName TargetPort int32 }
type ServiceMetadataMappingObjType ¶
type ServiceMetadataMappingObjType string
const ( GatewayVS ServiceMetadataMappingObjType = "GATEWAY_VS" ChildVS ServiceMetadataMappingObjType = "CHILD_VS" ServiceTypeLBVS ServiceMetadataMappingObjType = "SERVICELB_VS" GatewayPool ServiceMetadataMappingObjType = "GATEWAY_POOL" SNIInsecureOrEVHPool ServiceMetadataMappingObjType = "SNI_INSECURE_OR_EVH_POOL" )
type ServiceMetadataObj ¶
type ServiceMetadataObj struct { NamespaceIngressName []string `json:"namespace_ingress_name"` IngressName string `json:"ingress_name"` Namespace string `json:"namespace"` HostNames []string `json:"hostnames"` NamespaceServiceName []string `json:"namespace_svc_name"` // []string{ns/name} CRDStatus CRDMetadata `json:"crd_status"` PoolRatio uint32 `json:"pool_ratio"` PassthroughParentRef string `json:"passthrough_parent_ref"` PassthroughChildRef string `json:"passthrough_child_ref"` Gateway string `json:"gateway"` // ns/name InsecureEdgeTermAllow bool `json:"insecureedgetermallow"` IsMCIIngress bool `json:"is_mci_ingress"` }
func (ServiceMetadataObj) ServiceMetadataMapping ¶
func (c ServiceMetadataObj) ServiceMetadataMapping(objType string) ServiceMetadataMappingObjType
type ServicesAPIInformers ¶
type ServicesAPIInformers struct { GatewayInformer svcInformer.GatewayInformer GatewayClassInformer svcInformer.GatewayClassInformer }