Documentation ¶
Index ¶
Constants ¶
const ( // FrontendIPConfigIDTemplate is the template of the frontend IP configuration FrontendIPConfigIDTemplate = "/subscriptions/%s/resourceGroups/%s/providers/Microsoft.Network/loadBalancers/%s/frontendIPConfigurations/%s" // BackendPoolIDTemplate is the template of the backend pool BackendPoolIDTemplate = "/subscriptions/%s/resourceGroups/%s/providers/Microsoft.Network/loadBalancers/%s/backendAddressPools/%s" // LoadBalancerProbeIDTemplate is the template of the load balancer probe LoadBalancerProbeIDTemplate = "/subscriptions/%s/resourceGroups/%s/providers/Microsoft.Network/loadBalancers/%s/probes/%s" )
const (
// FinalizerName is the name for the finalizer.
FinalizerName = "mcn.networking.aks.io"
)
Variables ¶
This section is empty.
Functions ¶
func ContainsString ¶
func RemoveItemFromSlice ¶
Types ¶
type AKSClusterReconciler ¶
type AKSClusterReconciler struct { client.Client Scheme *runtime.Scheme WorkQueue workqueue.RateLimitingInterface Lock sync.Mutex ClusterManagers map[string]*ClusterManager }
AKSClusterReconciler reconciles a AKSCluster object
func (*AKSClusterReconciler) GetClusterManager ¶
func (r *AKSClusterReconciler) GetClusterManager(clusterName string) *ClusterManager
GetClusterManager gets the cluster manager by cluster name.
func (*AKSClusterReconciler) Reconcile ¶
func (r *AKSClusterReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the AKSCluster object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
func (*AKSClusterReconciler) SetupWithManager ¶
func (r *AKSClusterReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type ClusterManager ¶
func NewClusterManager ¶
func NewClusterManager(name string, kubeconfig *rest.Config, workqueue workqueue.RateLimitingInterface) (*ClusterManager, error)
NewClusterManager creates a new ClusterManager for a member cluster from its kubeconfig.
func (*ClusterManager) Run ¶
func (mgr *ClusterManager) Run() error
Run starts the cluster manager reconciler.
type ClusterSetReconciler ¶
ClusterSetReconciler reconciles a ClusterSet object
func (*ClusterSetReconciler) Reconcile ¶
func (r *ClusterSetReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the ClusterSet object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
func (*ClusterSetReconciler) SetupWithManager ¶
func (r *ClusterSetReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type GlobalServiceReconciler ¶
type GlobalServiceReconciler struct { client.Client Scheme *runtime.Scheme Manager ctrl.Manager Log logr.Logger AzureConfig *azureclients.AzureConfig LoadBalancerClient loadbalancerclient.Interface PublicIPClient publicipclient.Interface AKSClusterReconciler *AKSClusterReconciler AzureConfigSecret string AzureConfigNamespace string JitterPeriod time.Duration WorkQueue workqueue.RateLimitingInterface }
GlobalServiceReconciler reconciles a GlobalService object
func (*GlobalServiceReconciler) Reconcile ¶
func (r *GlobalServiceReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the GlobalService object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
func (*GlobalServiceReconciler) SetupWithManager ¶
func (r *GlobalServiceReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
func (*GlobalServiceReconciler) StartReconcileLoop ¶
func (r *GlobalServiceReconciler) StartReconcileLoop(ctx context.Context) error
StartReconcileLoop starts the reconciler loop for glb.
type RegionalIPConfig ¶
RegionalIPConfig defines the metadata for regional LB config.
type ServiceEndpoints ¶
type ServiceEndpoints struct { Cluster string Service types.NamespacedName LoadBalancerIP string Endpoints string // slice couldn't be used here because it would be used as map key. }
ServiceEndpoints defines the endpoints for the service.
type ServiceManager ¶
type ServiceManager struct { client.Client Name string Log logr.Logger Scheme *runtime.Scheme WorkQueue workqueue.RateLimitingInterface }
ServiceManager reconciles service objects inside member clusters.
func (*ServiceManager) SetupWithManager ¶
func (r *ServiceManager) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager registers ServiceManager reconciler.