namespacemapctrl

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2022 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Overview

Package namespacemapctrl contains NamespaceMap Controller logic and some functions for managing remote Namespaces.

Index

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
	LocalCluster          discoveryv1alpha1.ClusterIdentity
	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.

Directories

Path Synopsis
Package namespacemapctrltestutils provides utility function for namespaceMap controller testing.
Package namespacemapctrltestutils provides utility function for namespaceMap controller testing.

Jump to

Keyboard shortcuts

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