Documentation ¶
Overview ¶
Package namespacemapctrl contains NamespaceMap Controller logic and some functions for managing remote Namespaces.
Index ¶
- type NamespaceMapReconciler
- func (r *NamespaceMapReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
- func (r *NamespaceMapReconciler) RemoveNamespaceMapControllerFinalizer(ctx context.Context, nm *mapsv1alpha1.NamespaceMap) error
- func (r *NamespaceMapReconciler) SetNamespaceMapControllerFinalizer(ctx context.Context, nm *mapsv1alpha1.NamespaceMap) error
- func (r *NamespaceMapReconciler) SetupWithManager(mgr ctrl.Manager) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NamespaceMapReconciler ¶
type NamespaceMapReconciler struct { client.Client RemoteClients map[string]kubernetes.Interface IdentityManagerClient kubernetes.Interface LocalClusterID string RequeueTime time.Duration }
NamespaceMapReconciler creates remote namespaces and updates NamespaceMaps Status.
func (*NamespaceMapReconciler) Reconcile ¶
func (r *NamespaceMapReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile adds/removes NamespaceMap finalizer, and checks differences between DesiredMapping and CurrentMapping in order to create/delete remote Namespaces if it is necessary.
func (*NamespaceMapReconciler) RemoveNamespaceMapControllerFinalizer ¶ added in v0.3.0
func (r *NamespaceMapReconciler) RemoveNamespaceMapControllerFinalizer(ctx context.Context, nm *mapsv1alpha1.NamespaceMap) error
RemoveNamespaceMapControllerFinalizer remove the NamespaceMapController finalizer.
func (*NamespaceMapReconciler) SetNamespaceMapControllerFinalizer ¶ added in v0.3.0
func (r *NamespaceMapReconciler) SetNamespaceMapControllerFinalizer(ctx context.Context, nm *mapsv1alpha1.NamespaceMap) error
SetNamespaceMapControllerFinalizer adds NamespaceMapControllerFinalizer to a NamespaceMap, if it is not already there.
func (*NamespaceMapReconciler) SetupWithManager ¶
func (r *NamespaceMapReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager monitors only updates on NamespaceMap.