Documentation ¶
Overview ¶
Package v1 contains API Schema definitions for the epic v1 API group +kubebuilder:object:generate=true +groupName=epic.acnodal.io
Index ¶
- Constants
- Variables
- func AccountNamespace(acctName string) string
- func AllocateTunnelID(ctx context.Context, l logr.Logger, cl client.Client) (tunnelID uint32, err error)
- func GWProxyName(sgName string, lbName string, canBeShared bool) (name string)
- func HasEnvoyLabels(pod v1.Pod) bool
- func LabelsForEnvoy(name string) map[string]string
- func LabelsForProxy(name string) map[string]string
- func LoadBalancerName(sgName string, lbName string, canBeShared bool) (name string)
- func RemoteEndpointName(address net.IP, port int32, protocol v1.Protocol) string
- func RemovePodInfo(ctx context.Context, cl client.Client, ns string, name string, podName string) error
- func RemoveProxyInfo(ctx context.Context, cl client.Client, namespace string, proxyName string, ...) error
- type Account
- type AccountList
- type AccountSpec
- type AccountStatus
- type AddressPool
- func (ap *AddressPool) AddMultusRoute(lbIP net.IP) error
- func (in *AddressPool) DeepCopy() *AddressPool
- func (in *AddressPool) DeepCopyInto(out *AddressPool)
- func (ap *AddressPool) RemoveMultusRoute(ctx context.Context, r client.Reader, l logr.Logger, proxyName string, ...) error
- func (ap *AddressPool) SubnetIPNet() (*net.IPNet, error)
- type ClientRef
- type EPIC
- func (in *EPIC) DeepCopy() *EPIC
- func (in *EPIC) DeepCopyInto(out *EPIC)
- func (in *EPIC) DeepCopyObject() runtime.Object
- func (r *EPIC) Default()
- func (r *EPIC) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *EPIC) ValidateCreate() error
- func (r *EPIC) ValidateDelete() error
- func (r *EPIC) ValidateUpdate(old runtime.Object) error
- type EPICEndpointMap
- type EPICList
- type EPICSpec
- type EPICStatus
- type Endpoint
- func (in *Endpoint) DeepCopy() *Endpoint
- func (in *Endpoint) DeepCopyInto(out *Endpoint)
- func (e *Endpoint) GetProviderSpecificProperty(key string) (ProviderSpecificProperty, bool)
- func (e *Endpoint) String() string
- func (e *Endpoint) WithProviderSpecific(key, value string) *Endpoint
- func (e *Endpoint) WithSetIdentifier(setIdentifier string) *Endpoint
- type GUETunnelEndpoint
- type GWEndpointSlice
- func (in *GWEndpointSlice) DeepCopy() *GWEndpointSlice
- func (in *GWEndpointSlice) DeepCopyInto(out *GWEndpointSlice)
- func (in *GWEndpointSlice) DeepCopyObject() runtime.Object
- func (slice *GWEndpointSlice) ReferencingProxies(ctx context.Context, cl client.Client) ([]*GWProxy, error)
- func (slice *GWEndpointSlice) ToEndpoints() []RemoteEndpoint
- type GWEndpointSliceList
- type GWEndpointSliceSpec
- type GWEndpointSliceStatus
- type GWProxy
- func (proxy *GWProxy) ActiveProxyEndpoints(ctx context.Context, cl client.Client) ([]RemoteEndpoint, error)
- func (proxy *GWProxy) AddDNSEndpoint(lbsg LBServiceGroup) error
- func (lb *GWProxy) AgentFinalizerName(nodeName string) string
- func (in *GWProxy) DeepCopy() *GWProxy
- func (in *GWProxy) DeepCopyInto(out *GWProxy)
- func (in *GWProxy) DeepCopyObject() runtime.Object
- func (r *GWProxy) Default()
- func (proxy *GWProxy) GetChildRoutes(ctx context.Context, cl client.Client, l logr.Logger) ([]GWRoute, error)
- func (proxy *GWProxy) NamespacedName() types.NamespacedName
- func (proxy *GWProxy) Nudge(ctx context.Context, cl client.Client, l logr.Logger) error
- func (r *GWProxy) SetupWebhookWithManager(mgr ctrl.Manager, alloc PoolAllocator) error
- func (r *GWProxy) ValidateCreate() error
- func (r *GWProxy) ValidateDelete() error
- func (r *GWProxy) ValidateUpdate(old runtime.Object) error
- type GWProxyList
- type GWProxySpec
- type GWProxyStatus
- type GWRoute
- func (gwr *GWRoute) Backends() (backends []gatewayv1a2.BackendRef)
- func (in *GWRoute) DeepCopy() *GWRoute
- func (in *GWRoute) DeepCopyInto(out *GWRoute)
- func (in *GWRoute) DeepCopyObject() runtime.Object
- func (gwr *GWRoute) GWRouteName() string
- func (gwr *GWRoute) Parents() (parents []gatewayv1a2.ParentReference)
- type GWRouteList
- type GWRouteSpec
- type GWRouteStatus
- type LBServiceGroup
- func (in *LBServiceGroup) DeepCopy() *LBServiceGroup
- func (in *LBServiceGroup) DeepCopyInto(out *LBServiceGroup)
- func (in *LBServiceGroup) DeepCopyObject() runtime.Object
- func (lbsg *LBServiceGroup) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (lbsg *LBServiceGroup) ValidateCreate() error
- func (r *LBServiceGroup) ValidateDelete() error
- func (lbsg *LBServiceGroup) ValidateUpdate(old runtime.Object) error
- type LBServiceGroupList
- type LBServiceGroupSpec
- type LBServiceGroupStatus
- type Labels
- type LoadBalancer
- func (lb *LoadBalancer) AddDNSEndpoint(lbsg LBServiceGroup) error
- func (lb *LoadBalancer) AddUpstream(clusterID string) error
- func (lb *LoadBalancer) AgentFinalizerName(nodeName string) string
- func (lb *LoadBalancer) ContainsUpstream(contains string) bool
- func (in *LoadBalancer) DeepCopy() *LoadBalancer
- func (in *LoadBalancer) DeepCopyInto(out *LoadBalancer)
- func (in *LoadBalancer) DeepCopyObject() runtime.Object
- func (r *LoadBalancer) Default()
- func (lb *LoadBalancer) NamespacedName() types.NamespacedName
- func (lb *LoadBalancer) RemoveUpstream(clusterID string) error
- func (r *LoadBalancer) SetupWebhookWithManager(mgr ctrl.Manager, alloc PoolAllocator) error
- func (r *LoadBalancer) ValidateCreate() error
- func (r *LoadBalancer) ValidateDelete() error
- func (r *LoadBalancer) ValidateUpdate(old runtime.Object) error
- type LoadBalancerList
- type LoadBalancerSpec
- type LoadBalancerStatus
- type Node
- type PoolAllocator
- type ProviderSpecific
- type ProviderSpecificProperty
- type ProxyInterfaceInfo
- type RemoteEndpoint
- func (in *RemoteEndpoint) DeepCopy() *RemoteEndpoint
- func (in *RemoteEndpoint) DeepCopyInto(out *RemoteEndpoint)
- func (in *RemoteEndpoint) DeepCopyObject() runtime.Object
- func (r *RemoteEndpoint) Default()
- func (r *RemoteEndpoint) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *RemoteEndpoint) ValidateCreate() error
- func (r *RemoteEndpoint) ValidateDelete() error
- func (r *RemoteEndpoint) ValidateUpdate(old runtime.Object) error
- type RemoteEndpointList
- type RemoteEndpointSpec
- type RemoteEndpointStatus
- type ServicePrefix
- type ServicePrefixList
- type ServicePrefixSpec
- type ServicePrefixStatus
- type TTL
- type Targets
Constants ¶
const ( // IfIndexAnnotation is the key for the Pod annotation that contains // that Pod's proxy network interface index. IfIndexAnnotation string = "epic.acnodal.io/ifindex" // IfNameAnnotation is the key for the Pod annotation that contains // that Pod's proxy network interface name. IfNameAnnotation string = "epic.acnodal.io/ifname" )
const ( // OwnerLabelKey is the name of the label that defines the owner of an Endpoint. OwnerLabelKey = "owner" // ResourceLabelKey is the name of the label that identifies k8s resource which wants to acquire the DNS name ResourceLabelKey = "resource" // AWSSDDescriptionLabel label responsible for storing raw owner/resource combination information in the Labels // supposed to be inserted by AWS SD Provider, and parsed into OwnerLabelKey and ResourceLabelKey key by AWS SD Registry AWSSDDescriptionLabel = "aws-sd-description" // DualstackLabelKey is the name of the label that identifies dualstack endpoints DualstackLabelKey = "dualstack" )
const ( // RecordTypeA is a RecordType enum value RecordTypeA = "A" // RecordTypeCNAME is a RecordType enum value RecordTypeCNAME = "CNAME" // RecordTypeTXT is a RecordType enum value RecordTypeTXT = "TXT" // RecordTypeSRV is a RecordType enum value RecordTypeSRV = "SRV" // RecordTypeNS is a RecordType enum value RecordTypeNS = "NS" )
const ( // OwningAccountLabel is the name of the label that we apply to // service groups and load balancers to indicate in a query-friendly // way to which Account they belong. OwningAccountLabel string = GroupName + "/owning-account" // OwningLBServiceGroupLabel is the name of the label that we apply to // endpoints to indicate in a query-friendly way to which // LBServiceGroup they belong. OwningLBServiceGroupLabel string = GroupName + "/owning-lbservicegroup" // OwningServicePrefixLabel is the name of the label that we apply to // endpoints to indicate in a query-friendly way to which // ServicePrefix they belong. OwningServicePrefixLabel string = GroupName + "/owning-serviceprefix" // OwningLoadBalancerLabel is the name of the label that we apply to // endpoints to indicate in a query-friendly way to which // LoadBalancer they belong. OwningLoadBalancerLabel string = GroupName + "/owning-loadbalancer" // OwningProxyLabel is the name of the label that we apply to // endpoints to indicate in a query-friendly way to which // Proxy they belong. OwningProxyLabel string = GroupName + "/owning-proxy" // OwningClusterLabel is the name of the label that we apply to // endpoints to indicate in a query-friendly way to which Cluster // they belong. OwningClusterLabel string = GroupName + "/owning-cluster" )
const ( // ProductName is the name of our product. It's EPIC! ProductName = "epic" // ConfigName is the name of the EPIC configuration singleton. Its // namespace is defined in namespaces.go. ConfigName = ProductName // EDSServerName is the name of our dynamic endpoint discovery // service. EDSServerName string = "eds-server" // DiscoveryServiceName is the name of the Marin3r DiscoveryService // CR that we create in each customer namespace to tell Marin3r to // launch its discoveryservice in that namespace. DiscoveryServiceName string = "discoveryservice" )
const ( // MetricsNamespace is the namespace used with Prometheus. MetricsNamespace string = ProductName // ConfigNamespace is the namespace where we store the system // configuration objects like the EPIC singleton and the service // prefixes. ConfigNamespace string = ProductName // UserNamespacePrefix is the prefix used by all namespaces that are // EPIC User Namespaces. UserNamespacePrefix string = ProductName + "-" )
const (
AltAddressSuffix string = "-alt"
)
const (
FinalizerName = "epic.acnodal.io/controller"
)
const ( // GroupName is used in our API and as a prefix for annotation and // label keys. GroupName = "epic.acnodal.io" )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
var ( // ErrInvalidHeritage is returned when heritage was not found, or different heritage is found ErrInvalidHeritage = errors.New("heritage is unknown or not found") )
var ( // UserNSLabels is the set of labels that indicate that a k8s // namespace is an EPIC User Namespace. UserNSLabels = map[string]string{"app.kubernetes.io/component": "user-namespace", "app.kubernetes.io/part-of": ProductName} )
Functions ¶
func AccountNamespace ¶
AccountNamespace returns the namespace for the provided account name.
func AllocateTunnelID ¶
func AllocateTunnelID(ctx context.Context, l logr.Logger, cl client.Client) (tunnelID uint32, err error)
AllocateTunnelID allocates a tunnel ID from the EPIC singleton. If this call succeeds (i.e., error is nil) then the returned ID will be unique.
func GWProxyName ¶
GWProxyName returns the name that we use in the GWProxy custom resource. This is a combo of the ServicePrefix name and the "raw" load balancer name. We need to smash them together because one customer might have two or more LBs with the same name, but belonging to different service prefixes, and a customer's LBs all live in the same k8s namespace so we need to make the service group name into an ersatz namespace.
func HasEnvoyLabels ¶
HasEnvoyLabels indicates whether a Pod has the LabelsForEnvoy, i.e., whether the Pod is an Envoy proxy pod.
func LabelsForEnvoy ¶
LabelsForEnvoy returns the labels that we apply to a new Envoy proxy deployment.
func LabelsForProxy ¶
LabelsForProxy returns the labels that we apply to a new Envoy proxy deployment.
func LoadBalancerName ¶
LoadBalancerName returns the name that we use in the LoadBalancer custom resource. This is a combo of the ServicePrefix name and the "raw" load balancer name. We need to smash them together because one customer might have two or more LBs with the same name, but belonging to different service prefixes, and a customer's LBs all live in the same k8s namespace so we need to make the service group name into an ersatz namespace.
func RemoteEndpointName ¶
RemoteEndpointName makes a name for this rep that will be unique within this customer's namespace. It should also be somewhat human-readable which will hopefully help with debugging.
Types ¶
type Account ¶
type Account struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec AccountSpec `json:"spec,omitempty"` Status AccountStatus `json:"status,omitempty"` }
Account represents a business relationship between Acnodal and a third party. Since we know who we are, Account stores info about the third party and any info about our relationship that influences how the system operates.
func (*Account) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Account.
func (*Account) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Account) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type AccountList ¶
type AccountList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Account `json:"items"` }
AccountList contains a list of Account
func (*AccountList) DeepCopy ¶
func (in *AccountList) DeepCopy() *AccountList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccountList.
func (*AccountList) DeepCopyInto ¶
func (in *AccountList) DeepCopyInto(out *AccountList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*AccountList) DeepCopyObject ¶
func (in *AccountList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type AccountSpec ¶
type AccountSpec struct { // ProxyLimit defines how many proxies can be created in this // account. // +kubebuilder:default=2 ProxyLimit int `json:"proxyLimit,omitempty"` }
AccountSpec defines the desired state of Account
func (*AccountSpec) DeepCopy ¶
func (in *AccountSpec) DeepCopy() *AccountSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccountSpec.
func (*AccountSpec) DeepCopyInto ¶
func (in *AccountSpec) DeepCopyInto(out *AccountSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type AccountStatus ¶
type AccountStatus struct { }
AccountStatus defines the observed state of Account
func (*AccountStatus) DeepCopy ¶
func (in *AccountStatus) DeepCopy() *AccountStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccountStatus.
func (*AccountStatus) DeepCopyInto ¶
func (in *AccountStatus) DeepCopyInto(out *AccountStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type AddressPool ¶
type AddressPool struct { // Pool specifies a pool of addresses that PureLB manages. It can be // a CIDR or a from-to range of addresses, e.g., // 'fd53:9ef0:8683::-fd53:9ef0:8683::3'. Pool string `json:"pool"` // Subnet specifies the subnet that contains all of the addresses in // the Pool. It's specified with CIDR notation, e.g., // 'fd53:9ef0:8683::/120'. All of the addresses in the Pool must be // contained within the Subnet. Subnet string `json:"subnet"` // Aggregation changes the address mask of the allocated address // from the subnet mask to the specified mask. It can be "default" // or an integer in the range 8-128. Aggregation string `json:"aggregation"` // +kubebuilder:default=multus0 MultusBridge string `json:"multus-bridge,omitempty"` }
AddressPool specifies a pool of IP addresses.
func (*AddressPool) AddMultusRoute ¶
func (ap *AddressPool) AddMultusRoute(lbIP net.IP) error
AddMultusRoute adds a route to dest to this SP's multus bridge.
func (*AddressPool) DeepCopy ¶
func (in *AddressPool) DeepCopy() *AddressPool
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AddressPool.
func (*AddressPool) DeepCopyInto ¶
func (in *AddressPool) DeepCopyInto(out *AddressPool)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*AddressPool) RemoveMultusRoute ¶
func (ap *AddressPool) RemoveMultusRoute(ctx context.Context, r client.Reader, l logr.Logger, proxyName string, lbIP net.IP, spName string) error
RemoveMultusRoute removes the multus bridge route for lbIP only if no other proxy is using it. Because we can aggregate addresses, one route might attract traffic for more than one IP address. We don't want to remove a route until *all* of the IPs that depend on it are gone.
func (*AddressPool) SubnetIPNet ¶
func (ap *AddressPool) SubnetIPNet() (*net.IPNet, error)
SubnetIPNet returns this ServicePrefix's subnet in the form of a net.IPNet.
type ClientRef ¶
type ClientRef struct { ClusterID string `json:"clusterID,omitempty"` Namespace string `json:"namespace,omitempty"` Name string `json:"name,omitempty"` UID string `json:"uid,omitempty"` }
ClientRef provides the info needed to refer to a specific object in a specific cluster.
func (*ClientRef) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClientRef.
func (*ClientRef) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EPIC ¶
type EPIC struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec EPICSpec `json:"spec,omitempty"` Status EPICStatus `json:"status,omitempty"` }
EPIC is the Schema for the epics API
func (*EPIC) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EPIC.
func (*EPIC) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*EPIC) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*EPIC) Default ¶
func (r *EPIC) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*EPIC) SetupWebhookWithManager ¶
SetupWebhookWithManager sets up this webhook to be managed by mgr.
func (*EPIC) ValidateCreate ¶
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
type EPICEndpointMap ¶
type EPICEndpointMap struct {
EPICEndpoints map[string]GUETunnelEndpoint `json:"epic-endpoints,omitempty"`
}
EPICEndpointMap contains a map of the EPIC endpoints that connect to one PureLB endpoint, keyed by Node IP address.
func (*EPICEndpointMap) DeepCopy ¶
func (in *EPICEndpointMap) DeepCopy() *EPICEndpointMap
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EPICEndpointMap.
func (*EPICEndpointMap) DeepCopyInto ¶
func (in *EPICEndpointMap) DeepCopyInto(out *EPICEndpointMap)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EPICList ¶
type EPICList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []EPIC `json:"items"` }
EPICList contains a list of EPIC
func (*EPICList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EPICList.
func (*EPICList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*EPICList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type EPICSpec ¶
type EPICSpec struct { // EDSImage is the name of the EPIC EDS control plane Docker image // to run. // +kubebuilder:default="quay.io/epic-gateway/eds-server:latest" EDSImage string `json:"eds-image"` // EnvoyImage is the default Envoy Docker image name. This value can // be overridden by the EnvoyImage field in the lbservicegroup which // allows customers to specify their own Envoy images. EnvoyImage string `json:"envoy-image"` // XDSImage, if set, specifies the Marin3r discovery service image // to run. If not set, the default will be the image specified in // the marin3r deployment manifest. XDSImage *string `json:"xds-image,omitempty"` // ServiceCIDR is the pool from which internal service addresses are // allocated. In microk8s it's hard-coded and passed on the // kubeapiserver command line (see // epicmgr-resources/default-args/kube-apiserver). We need a way to // discover this value so we can configure routes in the Envoy pod. // The installer will set this value when it installs the epic // singleton custom resource. ServiceCIDR string `json:"service-cidr"` // NodeBase is the "base" configuration for all nodes in the // cluster. NodeBase Node `json:"base"` }
EPICSpec defines the desired state of EPIC
func (*EPICSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EPICSpec.
func (*EPICSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EPICStatus ¶
type EPICStatus struct { // CurrentGroupID is no longer used. CurrentGroupID uint16 `json:"current-group-id"` // CurrentTunnelID stores the most-recently-allocated tunnel // ID. Clients should read the CR, calculate the next value and then // write that back using Update() and not Patch(). If the write // succeeds then they own that value. If not then they need to try // again. CurrentTunnelID uint32 `json:"current-tunnel-id"` }
EPICStatus defines the observed state of EPIC
func (*EPICStatus) DeepCopy ¶
func (in *EPICStatus) DeepCopy() *EPICStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EPICStatus.
func (*EPICStatus) DeepCopyInto ¶
func (in *EPICStatus) DeepCopyInto(out *EPICStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Endpoint ¶
type Endpoint struct { // The hostname of the DNS record DNSName string `json:"dnsName,omitempty"` // The targets the DNS record points to Targets Targets `json:"targets,omitempty"` // RecordType type of record, e.g. CNAME, A, SRV, TXT etc RecordType string `json:"recordType,omitempty"` // Identifier to distinguish multiple records with the same name and type (e.g. Route53 records with routing policies other than 'simple') SetIdentifier string `json:"setIdentifier,omitempty"` // TTL for the record RecordTTL TTL `json:"recordTTL,omitempty"` // Labels stores labels defined for the Endpoint // +optional Labels Labels `json:"labels,omitempty"` // ProviderSpecific stores provider specific config // +optional ProviderSpecific ProviderSpecific `json:"providerSpecific,omitempty"` }
Endpoint is a high-level way of a connection between a service and an IP
func NewEndpoint ¶
NewEndpoint initialization method to be used to create an endpoint
func NewEndpointWithTTL ¶
NewEndpointWithTTL initialization method to be used to create an endpoint with a TTL struct
func (*Endpoint) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Endpoint.
func (*Endpoint) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Endpoint) GetProviderSpecificProperty ¶
func (e *Endpoint) GetProviderSpecificProperty(key string) (ProviderSpecificProperty, bool)
GetProviderSpecificProperty returns a ProviderSpecificProperty if the property exists.
func (*Endpoint) WithProviderSpecific ¶
WithProviderSpecific attaches a key/value pair to the Endpoint and returns the Endpoint. This can be used to pass additional data through the stages of ExternalDNS's Endpoint processing. The assumption is that most of the time this will be provider specific metadata that doesn't warrant its own field on the Endpoint object itself. It differs from Labels in the fact that it's not persisted in the Registry but only kept in memory during a single record synchronization.
func (*Endpoint) WithSetIdentifier ¶
WithSetIdentifier applies the given set identifier to the endpoint.
type GUETunnelEndpoint ¶
type GUETunnelEndpoint struct { // Address is the IP address on the EPIC for this endpoint. Address string `json:"epic-address,omitempty"` // Port is the port on which this endpoint listens. // +kubebuilder:default={"port":6080,"protocol":"UDP","appProtocol":"gue"} Port corev1.EndpointPort `json:"epic-port,omitempty"` // TunnelID is used to route traffic to the correct tunnel. TunnelID uint32 `json:"tunnel-id,omitempty"` }
GUETunnelEndpoint is an Endpoint on the EPIC.
func (*GUETunnelEndpoint) DeepCopy ¶
func (in *GUETunnelEndpoint) DeepCopy() *GUETunnelEndpoint
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GUETunnelEndpoint.
func (*GUETunnelEndpoint) DeepCopyInto ¶
func (in *GUETunnelEndpoint) DeepCopyInto(out *GUETunnelEndpoint)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWEndpointSlice ¶
type GWEndpointSlice struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec GWEndpointSliceSpec `json:"spec,omitempty"` Status GWEndpointSliceStatus `json:"status,omitempty"` }
GWEndpointSlice corresponds to an EndpointSlice object in a client cluster. It provides data for Envoy and to set up the GUE tunnels.
func (*GWEndpointSlice) DeepCopy ¶
func (in *GWEndpointSlice) DeepCopy() *GWEndpointSlice
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWEndpointSlice.
func (*GWEndpointSlice) DeepCopyInto ¶
func (in *GWEndpointSlice) DeepCopyInto(out *GWEndpointSlice)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWEndpointSlice) DeepCopyObject ¶
func (in *GWEndpointSlice) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*GWEndpointSlice) ReferencingProxies ¶
func (slice *GWEndpointSlice) ReferencingProxies(ctx context.Context, cl client.Client) ([]*GWProxy, error)
ReferencingProxies returns an array of the GWProxies that link to this slice via GWRoutes.
func (*GWEndpointSlice) ToEndpoints ¶
func (slice *GWEndpointSlice) ToEndpoints() []RemoteEndpoint
ToEndpoints represents this slice as an array of our LB RemoteEndpoints.
type GWEndpointSliceList ¶
type GWEndpointSliceList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []GWEndpointSlice `json:"items"` }
GWEndpointSliceList contains a list of GWEndpointSlice
func (*GWEndpointSliceList) DeepCopy ¶
func (in *GWEndpointSliceList) DeepCopy() *GWEndpointSliceList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWEndpointSliceList.
func (*GWEndpointSliceList) DeepCopyInto ¶
func (in *GWEndpointSliceList) DeepCopyInto(out *GWEndpointSliceList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWEndpointSliceList) DeepCopyObject ¶
func (in *GWEndpointSliceList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type GWEndpointSliceSpec ¶
type GWEndpointSliceSpec struct { // ClientRef points back to the client-side object that corresponds // to this one. ClientRef ClientRef `json:"clientRef,omitempty"` // ParentRef points to the client-side service that owns this slice. ParentRef ClientRef `json:"parentRef,omitempty"` // Slice holds the client-side EndpointSlice contents. discoveryv1.EndpointSlice `json:",inline"` // Map of node addresses. Key is node name, value is IP address // represented as string. NodeAddresses map[string]string `json:"nodeAddresses"` }
GWEndpointSliceSpec is a container for the EndpointSlice object in the client cluster. It also contains the info needed to find the object on the client side.
func (*GWEndpointSliceSpec) DeepCopy ¶
func (in *GWEndpointSliceSpec) DeepCopy() *GWEndpointSliceSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWEndpointSliceSpec.
func (*GWEndpointSliceSpec) DeepCopyInto ¶
func (in *GWEndpointSliceSpec) DeepCopyInto(out *GWEndpointSliceSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWEndpointSliceStatus ¶
type GWEndpointSliceStatus struct { }
GWEndpointSliceStatus defines the observed state of GWEndpointSlice.
func (*GWEndpointSliceStatus) DeepCopy ¶
func (in *GWEndpointSliceStatus) DeepCopy() *GWEndpointSliceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWEndpointSliceStatus.
func (*GWEndpointSliceStatus) DeepCopyInto ¶
func (in *GWEndpointSliceStatus) DeepCopyInto(out *GWEndpointSliceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWProxy ¶
type GWProxy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec GWProxySpec `json:"spec"` Status GWProxyStatus `json:"status,omitempty"` }
GWProxy is the Schema for the gwproxies API
func (*GWProxy) ActiveProxyEndpoints ¶
func (proxy *GWProxy) ActiveProxyEndpoints(ctx context.Context, cl client.Client) ([]RemoteEndpoint, error)
ActiveProxyEndpoints is a kludge to let us use old code that expects RemoteEndpoints with our new GWRoute/GWEndpointSlice models. It iterates through the GWRoutes and GWEndpointSlices and creates fake RemoteEndpoints that belong to the proxy and that are active, i.e., not in the process of being deleted.
func (*GWProxy) AddDNSEndpoint ¶
func (proxy *GWProxy) AddDNSEndpoint(lbsg LBServiceGroup) error
AddDNSEndpoint adds an external-dns Endpoint struct to the LB's Spec.Endpoints. The Endpoint is based on the LBSG's template and the DNS name is generated from a template. Parameters provided to the template: .LBName, .LBSGName, .ClusterServiceName, .ClusterServiceNS, .Account, .IPAddress (filtered to work in a DNS name).
func (*GWProxy) AgentFinalizerName ¶
AgentFinalizerName returns the finalizer name for the given nodeName.
func (*GWProxy) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWProxy.
func (*GWProxy) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWProxy) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*GWProxy) Default ¶
func (r *GWProxy) Default()
Default sets default values for this GWProxy object.
func (*GWProxy) GetChildRoutes ¶
func (proxy *GWProxy) GetChildRoutes(ctx context.Context, cl client.Client, l logr.Logger) ([]GWRoute, error)
GetChildRoutes lists the routes that reference this proxy and that are active, i.e., not in the process of being deleted.
func (*GWProxy) NamespacedName ¶
func (proxy *GWProxy) NamespacedName() types.NamespacedName
NamespacedName returns a NamespacedName object filled in with this Object's name info.
func (*GWProxy) Nudge ¶
Nudge "nudges" the GWProxy, i.e., causes its reconciler to fire, by adding a random annotation.
func (*GWProxy) SetupWebhookWithManager ¶
func (r *GWProxy) SetupWebhookWithManager(mgr ctrl.Manager, alloc PoolAllocator) error
SetupWebhookWithManager sets up this webhook to be managed by mgr.
func (*GWProxy) ValidateCreate ¶
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*GWProxy) ValidateDelete ¶
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
type GWProxyList ¶
type GWProxyList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []GWProxy `json:"items"` }
GWProxyList contains a list of GWProxy
func (*GWProxyList) DeepCopy ¶
func (in *GWProxyList) DeepCopy() *GWProxyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWProxyList.
func (*GWProxyList) DeepCopyInto ¶
func (in *GWProxyList) DeepCopyInto(out *GWProxyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWProxyList) DeepCopyObject ¶
func (in *GWProxyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type GWProxySpec ¶
type GWProxySpec struct { // ClientRef points back to the client-side object that corresponds // to this one. ClientRef ClientRef `json:"clientRef,omitempty"` // DisplayName is the publicly-visible load balancer name (i.e., // what the user specified). The CR name has a prefix and suffix to // disambiguate and we don't need to show those to the user. DisplayName string `json:"display-name,omitempty"` // PublicAddress is the publicly-visible IP address for this LB. PublicAddress string `json:"public-address,omitempty"` // AltAddress is a secondary IP address for this LB. When the // PublicAddress is an IPV6 address then we also need to attach an // IPV4 address to the proxy pod to enable IPV4 traffic in and out // of the pod. AltAddress string `json:"alt-address,omitempty"` // PublicPorts is the set of ports on which this LB will listen. PublicPorts []corev1.ServicePort `json:"public-ports,omitempty"` // TunnelKey authenticates clients with the EPIC. It must be a // base64-encoded 128-bit value. If not present, this will be filled // in by the defaulting webhook. TunnelKey string `json:"tunnel-key,omitempty"` // EnvoyTemplate is the template that will be used to configure // Envoy for the load balancers that belong to this LBServiceGroup. It // can be provided by the user, but if not it will be copied from // the owning LBServiceGroup. EnvoyTemplate *marin3r.EnvoyConfigSpec `json:"envoy-template,omitempty"` // EnvoyReplicaCount determines the number of Envoy proxy pod // replicas that will be launched for this GWProxy. If it's not // set then the controller will copy the value from the owning // LBServiceGroup. EnvoyReplicaCount *int32 `json:"envoy-replica-count,omitempty"` // GUETunnelEndpoints is a map of maps. The outer map is from client // node addresses to public GUE tunnel endpoints on the EPIC. The // map key is a client node address and must be one of the node // addresses in the Spec Endpoints slice. The value is a map // containing TunnelEndpoints that describes the public IPs and // ports to which the client can send tunnel ping packets. The key // is the IP address of the EPIC node and the value is a // TunnelEndpoint. GUETunnelMaps map[string]EPICEndpointMap `json:"gue-tunnel-endpoints,omitempty"` // ProxyInterfaces contains information about the Envoy proxy pods' // network interfaces. The map key is the proxy pod name. It's // filled in by the python setup-network daemon and used by the // gwproxy controller. ProxyInterfaces map[string]ProxyInterfaceInfo `json:"proxy-if-info,omitempty"` // Endpoints is a slice of DNS entries that external-dns will push // to our DNS provider. For now it typically holds one entry which // is generated from a template. Endpoints []*Endpoint `json:"endpoints,omitempty"` // Gateway is the client-side gatewayv1a2.GatewaySpec that // corresponds to this GWP. Gateway gatewayv1a2.GatewaySpec `json:"gateway,omitempty"` }
GWProxySpec defines the desired state of GWProxy
func (*GWProxySpec) DeepCopy ¶
func (in *GWProxySpec) DeepCopy() *GWProxySpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWProxySpec.
func (*GWProxySpec) DeepCopyInto ¶
func (in *GWProxySpec) DeepCopyInto(out *GWProxySpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWProxyStatus ¶
type GWProxyStatus struct { // The generation observed by the external-dns controller. // +optional ObservedGeneration int64 `json:"observedGeneration,omitempty"` }
GWProxyStatus defines the observed state of GWProxy
func (*GWProxyStatus) DeepCopy ¶
func (in *GWProxyStatus) DeepCopy() *GWProxyStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWProxyStatus.
func (*GWProxyStatus) DeepCopyInto ¶
func (in *GWProxyStatus) DeepCopyInto(out *GWProxyStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWRoute ¶
type GWRoute struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec GWRouteSpec `json:"spec,omitempty"` Status GWRouteStatus `json:"status,omitempty"` }
GWRoute is the Schema for the gwroutes API
func (*GWRoute) Backends ¶
func (gwr *GWRoute) Backends() (backends []gatewayv1a2.BackendRef)
Backends returns a slice containing this GWR's BackendReferences.
func (*GWRoute) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWRoute.
func (*GWRoute) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWRoute) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*GWRoute) GWRouteName ¶
GWRouteName makes a name for this route that will be unique within this customer's namespace. It should also be somewhat human-readable which will hopefully help with debugging.
func (*GWRoute) Parents ¶
func (gwr *GWRoute) Parents() (parents []gatewayv1a2.ParentReference)
Parents returns a slice containing this GWR's ParentReferences.
type GWRouteList ¶
type GWRouteList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []GWRoute `json:"items"` }
GWRouteList contains a list of GWRoute
func (*GWRouteList) DeepCopy ¶
func (in *GWRouteList) DeepCopy() *GWRouteList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWRouteList.
func (*GWRouteList) DeepCopyInto ¶
func (in *GWRouteList) DeepCopyInto(out *GWRouteList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*GWRouteList) DeepCopyObject ¶
func (in *GWRouteList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type GWRouteSpec ¶
type GWRouteSpec struct { // ClientRef points back to the client-side object that corresponds // to this one. ClientRef ClientRef `json:"clientRef,omitempty"` HTTP *gatewayv1a2.HTTPRouteSpec `json:"http,omitempty"` TCP *gatewayv1a2.TCPRouteSpec `json:"tcp,omitempty"` }
GWRouteSpec is our wrapper for the various types of Gateway RouteSpecs.
func (*GWRouteSpec) DeepCopy ¶
func (in *GWRouteSpec) DeepCopy() *GWRouteSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWRouteSpec.
func (*GWRouteSpec) DeepCopyInto ¶
func (in *GWRouteSpec) DeepCopyInto(out *GWRouteSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GWRouteStatus ¶
type GWRouteStatus struct { }
GWRouteStatus defines the observed state of GWRoute
func (*GWRouteStatus) DeepCopy ¶
func (in *GWRouteStatus) DeepCopy() *GWRouteStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GWRouteStatus.
func (*GWRouteStatus) DeepCopyInto ¶
func (in *GWRouteStatus) DeepCopyInto(out *GWRouteStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LBServiceGroup ¶
type LBServiceGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LBServiceGroupSpec `json:"spec,omitempty"` Status LBServiceGroupStatus `json:"status,omitempty"` }
LBServiceGroup is the Schema for the lbservicegroups API
func (*LBServiceGroup) DeepCopy ¶
func (in *LBServiceGroup) DeepCopy() *LBServiceGroup
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LBServiceGroup.
func (*LBServiceGroup) DeepCopyInto ¶
func (in *LBServiceGroup) DeepCopyInto(out *LBServiceGroup)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LBServiceGroup) DeepCopyObject ¶
func (in *LBServiceGroup) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*LBServiceGroup) SetupWebhookWithManager ¶
func (lbsg *LBServiceGroup) SetupWebhookWithManager(mgr ctrl.Manager) error
SetupWebhookWithManager sets up this webhook to be managed by mgr.
func (*LBServiceGroup) ValidateCreate ¶
func (lbsg *LBServiceGroup) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*LBServiceGroup) ValidateDelete ¶
func (r *LBServiceGroup) ValidateDelete() error
ValidateDelete does nothing and it's never called.
func (*LBServiceGroup) ValidateUpdate ¶
func (lbsg *LBServiceGroup) ValidateUpdate(old runtime.Object) error
ValidateUpdate does the same thing that ValidateCreate does.
type LBServiceGroupList ¶
type LBServiceGroupList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LBServiceGroup `json:"items"` }
LBServiceGroupList contains a list of LBServiceGroup
func (*LBServiceGroupList) DeepCopy ¶
func (in *LBServiceGroupList) DeepCopy() *LBServiceGroupList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LBServiceGroupList.
func (*LBServiceGroupList) DeepCopyInto ¶
func (in *LBServiceGroupList) DeepCopyInto(out *LBServiceGroupList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LBServiceGroupList) DeepCopyObject ¶
func (in *LBServiceGroupList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LBServiceGroupSpec ¶
type LBServiceGroupSpec struct { // be shared among multiple PureLB services. // +kubebuilder:default=false CanBeShared bool `json:"can-be-shared"` // EnvoyImage is the Envoy Docker image name. If this is not set // then the image specified in the EPIC config singleton EnvoyImage // field will be used. EnvoyImage *string `json:"envoy-image,omitempty"` // EnvoyReplicaCount determines the number of Envoy proxy pod // replicas that will be launched for each LoadBalancer. It can be // overridden by the LoadBalancer CR. // +kubebuilder:default=1 EnvoyReplicaCount int32 `json:"envoy-replica-count"` // EnvoyTemplate is the template that will be used to configure // Envoy for the load balancers that belong to this LBServiceGroup. EnvoyTemplate marin3r.EnvoyConfigSpec `json:"envoy-template"` // EndpointTemplate is the template that will be used to fill in the // Spec.Endpoints field in load balancers that belong to this // LBServiceGroup. // +kubebuilder:default={"recordType":"A","recordTTL":180,"dnsName":"{{.PureLBServiceName}}.{{.LBSGName}}.client.acnodal.io"} EndpointTemplate Endpoint `json:"endpoint-template"` }
LBServiceGroupSpec defines the desired state of LBServiceGroup
func (*LBServiceGroupSpec) DeepCopy ¶
func (in *LBServiceGroupSpec) DeepCopy() *LBServiceGroupSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LBServiceGroupSpec.
func (*LBServiceGroupSpec) DeepCopyInto ¶
func (in *LBServiceGroupSpec) DeepCopyInto(out *LBServiceGroupSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LBServiceGroupStatus ¶
type LBServiceGroupStatus struct { // ProxySnapshotVersions is a map of current Envoy proxy // configuration snapshot versions for the LBs that belong to this // LBServiceGroup. Each increments every time the snapshot changes. We // store them here because they need to survive pod restarts. // +kubebuilder:default={} ProxySnapshotVersions map[string]int `json:"proxy-snapshot-versions"` }
LBServiceGroupStatus defines the observed state of LBServiceGroup
func (*LBServiceGroupStatus) DeepCopy ¶
func (in *LBServiceGroupStatus) DeepCopy() *LBServiceGroupStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LBServiceGroupStatus.
func (*LBServiceGroupStatus) DeepCopyInto ¶
func (in *LBServiceGroupStatus) DeepCopyInto(out *LBServiceGroupStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Labels ¶
Labels store metadata related to the endpoint it is then stored in a persistent storage via serialization
func NewLabelsFromString ¶
NewLabelsFromString constructs endpoints labels from a provided format string if heritage set to another value is found then error is returned no heritage automatically assumes is not owned by external-dns and returns invalidHeritage error
func (Labels) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Labels.
func (Labels) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LoadBalancer ¶
type LoadBalancer struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LoadBalancerSpec `json:"spec"` Status LoadBalancerStatus `json:"status,omitempty"` }
LoadBalancer is the Schema for the loadbalancers API
func (*LoadBalancer) AddDNSEndpoint ¶
func (lb *LoadBalancer) AddDNSEndpoint(lbsg LBServiceGroup) error
AddDNSEndpoint adds an external-dns Endpoint struct to the LB's Spec.Endpoints. The Endpoint is based on the LBSG's template and the DNS name is generated from a template. Two parameters are provided to the template: .LBName and .LBSGName.
func (*LoadBalancer) AddUpstream ¶
func (lb *LoadBalancer) AddUpstream(clusterID string) error
AddUpstream adds "clusterId" as an upstream cluster to this LB. Returns an error if the LB already contained the cluster, nil if it didn't.
func (*LoadBalancer) AgentFinalizerName ¶
func (lb *LoadBalancer) AgentFinalizerName(nodeName string) string
AgentFinalizerName returns the finalizer name for the given nodeName.
func (*LoadBalancer) ContainsUpstream ¶
func (lb *LoadBalancer) ContainsUpstream(contains string) bool
ContainsUpstream indicates whether "contains" is already registered as an upstream cluster. Returns true if it is, false if it isn't.
func (*LoadBalancer) DeepCopy ¶
func (in *LoadBalancer) DeepCopy() *LoadBalancer
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoadBalancer.
func (*LoadBalancer) DeepCopyInto ¶
func (in *LoadBalancer) DeepCopyInto(out *LoadBalancer)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LoadBalancer) DeepCopyObject ¶
func (in *LoadBalancer) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*LoadBalancer) Default ¶
func (r *LoadBalancer) Default()
Default sets default values for this LoadBalancer object.
func (*LoadBalancer) NamespacedName ¶
func (lb *LoadBalancer) NamespacedName() types.NamespacedName
NamespacedName returns a NamespacedName object filled in with this Object's name info.
func (*LoadBalancer) RemoveUpstream ¶
func (lb *LoadBalancer) RemoveUpstream(clusterID string) error
RemoveUpstream removes "clusterId" as an upstream cluster from this LB. Returns nil if the LB already contained the cluster, an error if it didn't.
func (*LoadBalancer) SetupWebhookWithManager ¶
func (r *LoadBalancer) SetupWebhookWithManager(mgr ctrl.Manager, alloc PoolAllocator) error
SetupWebhookWithManager sets up this webhook to be managed by mgr.
func (*LoadBalancer) ValidateCreate ¶
func (r *LoadBalancer) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*LoadBalancer) ValidateDelete ¶
func (r *LoadBalancer) ValidateDelete() error
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (*LoadBalancer) ValidateUpdate ¶
func (r *LoadBalancer) ValidateUpdate(old runtime.Object) error
ValidateUpdate does nothing.
type LoadBalancerList ¶
type LoadBalancerList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LoadBalancer `json:"items"` }
LoadBalancerList contains a list of LoadBalancer
func (*LoadBalancerList) DeepCopy ¶
func (in *LoadBalancerList) DeepCopy() *LoadBalancerList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoadBalancerList.
func (*LoadBalancerList) DeepCopyInto ¶
func (in *LoadBalancerList) DeepCopyInto(out *LoadBalancerList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LoadBalancerList) DeepCopyObject ¶
func (in *LoadBalancerList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LoadBalancerSpec ¶
type LoadBalancerSpec struct { // DisplayName is the publicly-visible load balancer name (i.e., // what the user specified). The CR name has a prefix and suffix to // disambiguate and we don't need to show those to the user. DisplayName string `json:"display-name,omitempty"` // PublicAddress is the publicly-visible IP address for this LB. PublicAddress string `json:"public-address,omitempty"` // PublicPorts is the set of ports on which this LB will listen. PublicPorts []corev1.ServicePort `json:"public-ports,omitempty"` // TunnelKey authenticates clients with the EPIC. It must be a // base64-encoded 128-bit value. If not present, this will be filled // in by the defaulting webhook. TunnelKey string `json:"tunnel-key,omitempty"` // EnvoyTemplate is the template that will be used to configure // Envoy for the load balancers that belong to this LBServiceGroup. It // can be provided by the user, but if not it will be copied from // the owning LBServiceGroup. EnvoyTemplate *marin3r.EnvoyConfigSpec `json:"envoy-template,omitempty"` // EnvoyReplicaCount determines the number of Envoy proxy pod // replicas that will be launched for this LoadBalancer. If it's not // set then the controller will copy the value from the owning // LBServiceGroup. EnvoyReplicaCount *int32 `json:"envoy-replica-count,omitempty"` // UpstreamClusters is a list of the names of the upstream clusters // (currently only PureLB but maybe other types in the future) that // this LB serves. The string must be the cluster-id that is passed // in the announce and withdraw web service methods. UpstreamClusters []string `json:"upstream-clusters,omitempty"` // TrueIngress indicates that this LB will use TrueIngress to talk // to its upstream cluster endpoints. The default is true since that // will likely be the most common case. // +kubebuilder:default=true TrueIngress bool `json:"true-ingress"` // GUETunnelEndpoints is a map of maps. The outer map is from client // node addresses to public GUE tunnel endpoints on the EPIC. The // map key is a client node address and must be one of the node // addresses in the Spec Endpoints slice. The value is a map // containing TunnelEndpoints that describes the public IPs and // ports to which the client can send tunnel ping packets. The key // is the IP address of the EPIC node and the value is a // TunnelEndpoint. GUETunnelMaps map[string]EPICEndpointMap `json:"gue-tunnel-endpoints,omitempty"` // ProxyInterfaces contains information about the Envoy proxy pods' // network interfaces. The map key is the proxy pod name. It's // filled in by the python setup-network daemon and used by the // loadbalancer controller. ProxyInterfaces map[string]ProxyInterfaceInfo `json:"proxy-if-info,omitempty"` Endpoints []*Endpoint `json:"endpoints,omitempty"` }
LoadBalancerSpec defines the desired state of LoadBalancer
func (*LoadBalancerSpec) DeepCopy ¶
func (in *LoadBalancerSpec) DeepCopy() *LoadBalancerSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoadBalancerSpec.
func (*LoadBalancerSpec) DeepCopyInto ¶
func (in *LoadBalancerSpec) DeepCopyInto(out *LoadBalancerSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LoadBalancerStatus ¶
type LoadBalancerStatus struct { // The generation observed by the external-dns controller. // +optional ObservedGeneration int64 `json:"observedGeneration,omitempty"` }
LoadBalancerStatus defines the observed state of LoadBalancer
func (*LoadBalancerStatus) DeepCopy ¶
func (in *LoadBalancerStatus) DeepCopy() *LoadBalancerStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoadBalancerStatus.
func (*LoadBalancerStatus) DeepCopyInto ¶
func (in *LoadBalancerStatus) DeepCopyInto(out *LoadBalancerStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Node ¶
type Node struct { // +kubebuilder:default={"enp1s0"} IngressNICs []string `json:"gue-ingress-nics,omitempty"` // +kubebuilder:default={"epic-port":{"port":6080,"protocol":"UDP","appProtocol":"gue"}} GUEEndpoint GUETunnelEndpoint `json:"gue-endpoint,omitempty"` }
Node is the config for one node.
func (*Node) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Node.
func (*Node) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Node) IngressIPAddr ¶
IngressIPAddr returns the first IP address from the first interface in this node's IngressNICs list. If error is non-nil then something has gone wrong.
type PoolAllocator ¶
type PoolAllocator interface {
AllocateFromPool(string, string, []corev1.ServicePort, string) (net.IP, error)
}
PoolAllocator allocates addresses. We use an interface to avoid import loops between the v1 package and the allocator package.
+kubebuilder:object:generate=false
type ProviderSpecific ¶
type ProviderSpecific []ProviderSpecificProperty
ProviderSpecific holds configuration which is specific to individual DNS providers
func (ProviderSpecific) DeepCopy ¶
func (in ProviderSpecific) DeepCopy() ProviderSpecific
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderSpecific.
func (ProviderSpecific) DeepCopyInto ¶
func (in ProviderSpecific) DeepCopyInto(out *ProviderSpecific)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProviderSpecificProperty ¶
type ProviderSpecificProperty struct { Name string `json:"name,omitempty"` Value string `json:"value,omitempty"` }
ProviderSpecificProperty holds the name and value of a configuration which is specific to individual DNS providers
func (*ProviderSpecificProperty) DeepCopy ¶
func (in *ProviderSpecificProperty) DeepCopy() *ProviderSpecificProperty
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderSpecificProperty.
func (*ProviderSpecificProperty) DeepCopyInto ¶
func (in *ProviderSpecificProperty) DeepCopyInto(out *ProviderSpecificProperty)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProxyInterfaceInfo ¶
type ProxyInterfaceInfo struct { // EPICNodeAddress is the IP address of the EPIC node that hosts // this proxy pod. EPICNodeAddress string `json:"epic-node-address,omitempty"` // Port is the port on which this endpoint listens. // +kubebuilder:default={"port":6080,"protocol":"UDP","appProtocol":"gue"} Port corev1.EndpointPort `json:"epic-port,omitempty"` // Index is the ifindex of the Envoy proxy pod's veth interface on // the CRI side of this service's proxy pod. In other words, it's // the end of the veth that's inside the container (i.e., on the // other side from the end that's attached to the multus bridge). Index int `json:"index,omitempty"` // Name is the name of the interface whose index is ProxyIfindex. Name string `json:"name,omitempty"` }
ProxyInterfaceInfo contains information about the Envoy proxy pod's network interfaces.
func (*ProxyInterfaceInfo) DeepCopy ¶
func (in *ProxyInterfaceInfo) DeepCopy() *ProxyInterfaceInfo
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyInterfaceInfo.
func (*ProxyInterfaceInfo) DeepCopyInto ¶
func (in *ProxyInterfaceInfo) DeepCopyInto(out *ProxyInterfaceInfo)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RemoteEndpoint ¶
type RemoteEndpoint struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec RemoteEndpointSpec `json:"spec,omitempty"` Status RemoteEndpointStatus `json:"status,omitempty"` }
RemoteEndpoint represents a service endpoint on a remote customer cluster.
func (*RemoteEndpoint) DeepCopy ¶
func (in *RemoteEndpoint) DeepCopy() *RemoteEndpoint
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteEndpoint.
func (*RemoteEndpoint) DeepCopyInto ¶
func (in *RemoteEndpoint) DeepCopyInto(out *RemoteEndpoint)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*RemoteEndpoint) DeepCopyObject ¶
func (in *RemoteEndpoint) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*RemoteEndpoint) Default ¶
func (r *RemoteEndpoint) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*RemoteEndpoint) SetupWebhookWithManager ¶
func (r *RemoteEndpoint) SetupWebhookWithManager(mgr ctrl.Manager) error
SetupWebhookWithManager sets up this webhook to be managed by mgr.
func (*RemoteEndpoint) ValidateCreate ¶
func (r *RemoteEndpoint) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*RemoteEndpoint) ValidateDelete ¶
func (r *RemoteEndpoint) ValidateDelete() error
ValidateDelete does nothing.
func (*RemoteEndpoint) ValidateUpdate ¶
func (r *RemoteEndpoint) ValidateUpdate(old runtime.Object) error
ValidateUpdate does nothing.
type RemoteEndpointList ¶
type RemoteEndpointList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []RemoteEndpoint `json:"items"` }
RemoteEndpointList contains a list of RemoteEndpoint
func (*RemoteEndpointList) DeepCopy ¶
func (in *RemoteEndpointList) DeepCopy() *RemoteEndpointList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteEndpointList.
func (*RemoteEndpointList) DeepCopyInto ¶
func (in *RemoteEndpointList) DeepCopyInto(out *RemoteEndpointList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*RemoteEndpointList) DeepCopyObject ¶
func (in *RemoteEndpointList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type RemoteEndpointSpec ¶
type RemoteEndpointSpec struct { // Cluster is the cluster-id of the cluster to which this rep // belongs. Cluster string `json:"cluster"` // Address is the IP address for this endpoint. Address string `json:"address"` // NodeAddress is the IP address of the node on which this endpoint // is running. We use it to set up a GUE tunnel from the EPIC to the // node. If it is not set then this endpoint will be ad-hoc, i.e., // it won't use GUE. NodeAddress string `json:"node-address,omitempty"` // Port is the port on which this endpoint listens. Port corev1.EndpointPort `json:"port"` }
RemoteEndpointSpec defines the desired state of RemoteEndpoint. It represents one pod endpoint on a customer cluster.
func (*RemoteEndpointSpec) DeepCopy ¶
func (in *RemoteEndpointSpec) DeepCopy() *RemoteEndpointSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteEndpointSpec.
func (*RemoteEndpointSpec) DeepCopyInto ¶
func (in *RemoteEndpointSpec) DeepCopyInto(out *RemoteEndpointSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RemoteEndpointStatus ¶
type RemoteEndpointStatus struct { // The ProxyIfindex in the GWProxy Status is canonical but we // cache it here so we can cleanup the PFC service without having to // lookup the GWP since it might have been deleted. ProxyIfindex int `json:"proxy-ifindex,omitempty"` // The TunnelID in the GWProxy Status is canonical but we cache // it here so we can cleanup the PFC service without having to // lookup the GWP since it might have been deleted. TunnelID uint32 `json:"tunnel-id,omitempty"` }
RemoteEndpointStatus defines the observed state of RemoteEndpoint
func (*RemoteEndpointStatus) DeepCopy ¶
func (in *RemoteEndpointStatus) DeepCopy() *RemoteEndpointStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RemoteEndpointStatus.
func (*RemoteEndpointStatus) DeepCopyInto ¶
func (in *RemoteEndpointStatus) DeepCopyInto(out *RemoteEndpointStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ServicePrefix ¶
type ServicePrefix struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ServicePrefixSpec `json:"spec,omitempty"` Status ServicePrefixStatus `json:"status,omitempty"` }
ServicePrefix represents a pool of IP addresses. The EPIC web service will allocate addresses from the set of ServicePrefixes.
func (*ServicePrefix) DeepCopy ¶
func (in *ServicePrefix) DeepCopy() *ServicePrefix
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePrefix.
func (*ServicePrefix) DeepCopyInto ¶
func (in *ServicePrefix) DeepCopyInto(out *ServicePrefix)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ServicePrefix) DeepCopyObject ¶
func (in *ServicePrefix) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*ServicePrefix) Default ¶
func (r *ServicePrefix) Default()
Default sets default values for this LoadBalancer object.
func (*ServicePrefix) SetupWebhookWithManager ¶
func (r *ServicePrefix) SetupWebhookWithManager(mgr ctrl.Manager) error
SetupWebhookWithManager sets up this webhook to be managed by mgr.
type ServicePrefixList ¶
type ServicePrefixList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []ServicePrefix `json:"items"` }
ServicePrefixList contains a list of ServicePrefix
func (*ServicePrefixList) DeepCopy ¶
func (in *ServicePrefixList) DeepCopy() *ServicePrefixList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePrefixList.
func (*ServicePrefixList) DeepCopyInto ¶
func (in *ServicePrefixList) DeepCopyInto(out *ServicePrefixList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ServicePrefixList) DeepCopyObject ¶
func (in *ServicePrefixList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ServicePrefixSpec ¶
type ServicePrefixSpec struct { // PublicAddress is a secondary IP address pool for this SP. When // the Pool contains IPV6 addresses then we also need a pool of IPV4 // addresses to attach to the proxy pod (to enable IPV4 traffic in // and out of the pod). PublicPool *AddressPool `json:"public-pool,omitempty"` // AltAddress is a secondary IP address pool for this SP. When the // Pool contains IPV6 addresses then we also need a pool of IPV4 // addresses to attach to the proxy pod (to enable IPV4 traffic in // and out of the pod). AltPool *AddressPool `json:"alt-pool,omitempty"` }
ServicePrefixSpec defines the desired state of ServicePrefix
func (*ServicePrefixSpec) DeepCopy ¶
func (in *ServicePrefixSpec) DeepCopy() *ServicePrefixSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePrefixSpec.
func (*ServicePrefixSpec) DeepCopyInto ¶
func (in *ServicePrefixSpec) DeepCopyInto(out *ServicePrefixSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ServicePrefixStatus ¶
type ServicePrefixStatus struct { }
ServicePrefixStatus defines the observed state of ServicePrefix
func (*ServicePrefixStatus) DeepCopy ¶
func (in *ServicePrefixStatus) DeepCopy() *ServicePrefixStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServicePrefixStatus.
func (*ServicePrefixStatus) DeepCopyInto ¶
func (in *ServicePrefixStatus) DeepCopyInto(out *ServicePrefixStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type TTL ¶
type TTL int64
TTL is a structure defining the TTL of a DNS record
func (TTL) IsConfigured ¶
IsConfigured returns true if TTL is configured, false otherwise
type Targets ¶
type Targets []string
Targets is a representation of a list of targets for an endpoint.
func NewTargets ¶
NewTargets is a convenience method to create a new Targets object from a vararg of strings
func (Targets) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Targets.
func (Targets) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (Targets) IsLess ¶
IsLess should fulfill the requirement to compare two targets and choose the 'lesser' one. In the past target was a simple string so simple string comparison could be used. Now we define 'less' as either being the shorter list of targets or where the first entry is less. FIXME We really need to define under which circumstances a list Targets is considered 'less' than another.
Source Files ¶
- account_types.go
- annotations.go
- clientref_types.go
- dns_labels.go
- endpoint.go
- epic_types.go
- epic_webhook.go
- finalizers.go
- groupversion_info.go
- gwendpointslice_types.go
- gwproxy_types.go
- gwproxy_webhook.go
- gwroute_types.go
- labels.go
- lbservicegroup_types.go
- lbservicegroup_webhook.go
- loadbalancer_types.go
- loadbalancer_webhook.go
- names.go
- namespaces.go
- remoteendpoint_types.go
- remoteendpoint_webhook.go
- rfc1123.go
- serviceprefix_types.go
- serviceprefix_webhook.go
- zz_generated.deepcopy.go