Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CachedDiscoveryClient ¶ added in v1.6.0
type CachedDiscoveryClient struct {
// contains filtered or unexported fields
}
CachedDiscoveryClient is a wrapper around the discovery client that caches the API resources for a period of time.
func NewDiscoveryClient ¶ added in v1.6.0
func NewDiscoveryClient(cfg *rest.Config, period time.Duration) *CachedDiscoveryClient
NewDiscoveryClient creates a new CachedDiscoveryClient.
func (*CachedDiscoveryClient) GetAPIResourceListMapping ¶ added in v1.6.0
func (c *CachedDiscoveryClient) GetAPIResourceListMapping() (map[schema.GroupVersion]*metav1.APIResourceList, error)
GetAPIResourceListMapping returns the GroupVersion to API resources map.
type ControlPlaneFinalizer ¶
type ControlPlaneFinalizer string
ControlPlaneFinalizer defines finalizers added by controlplane controller.
const ( // ControlPlaneFinalizerCleanupClusterRole is the finalizer to cleanup clusterroles owned by controlplane on deleting. ControlPlaneFinalizerCleanupClusterRole ControlPlaneFinalizer = "gateway-operator.konghq.com/cleanup-clusterrole" // ControlPlaneFinalizerCleanupClusterRoleBinding is the finalizer to cleanup clusterrolebindings owned by controlplane on deleting. ControlPlaneFinalizerCleanupClusterRoleBinding ControlPlaneFinalizer = "gateway-operator.konghq.com/cleanup-clusterrolebinding" // ControlPlaneFinalizerCleanupValidatingWebhookConfiguration is the finalizer to cleanup validatingwebhookconfigurations owned by controlplane on deleting. ControlPlaneFinalizerCleanupValidatingWebhookConfiguration ControlPlaneFinalizer = "gateway-operator.konghq.com/cleanup-validatingwebhookconfiguration" )
type Reconciler ¶
type Reconciler struct { client.Client DiscoveryClient *CachedDiscoveryClient Scheme *runtime.Scheme ClusterCASecretName string ClusterCASecretNamespace string ClusterCAKeyConfig secrets.KeyConfig KonnectEnabled bool EnforceConfig bool LoggingMode logging.Mode ValidateControlPlaneImage bool AnonymousReportsEnabled bool }
Reconciler reconciles a ControlPlane object
func (*Reconciler) ClusterScopedObjHasControlPlaneOwner ¶ added in v1.3.0
func (r *Reconciler) ClusterScopedObjHasControlPlaneOwner(ctx context.Context, obj client.Object) bool
ClusterScopedObjHasControlPlaneOwner checks if the cluster-scoped object has a control plane owner. The check is performed through the managed-by-name label.
func (*Reconciler) Reconcile ¶
Reconcile moves the current state of an object to the intended state.
func (*Reconciler) SetupWithManager ¶
SetupWithManager sets up the controller with the Manager.