controllers

package
v0.2.0-snapshot Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2021 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultCRName = "nhc-worker-default"

DefaultCRName is the name of default NHC resource the controller creates in case there are no others already.

View Source
const DefaultPoisonPillTemplateName = "poison-pill-default-template"

DefaultPoisonPillTemplateName is the name of the poison-pill template the default NHC uses.

Variables

This section is empty.

Functions

func NewNodeHealthcheckController added in v0.1.0

func NewNodeHealthcheckController(mgr manager.Manager) error

NewNodeHealthcheckController setups the Node Health Check controller with the controller manager and ensures at least one NHC resource exists. If there is no NHC resource it will create one with the name in #DefaultCRName that works with poison-pill template by the name in #DefaultPoisonPillTemplateName on the same namespace this controller is deployed.

Types

type NodeHealthCheckReconciler

type NodeHealthCheckReconciler struct {
	client.Client
	DynamicClient dynamic.Interface
	Log           logr.Logger
	Scheme        *runtime.Scheme
	// contains filtered or unexported fields
}

NodeHealthCheckReconciler reconciles a NodeHealthCheck object

func (*NodeHealthCheckReconciler) Reconcile

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 NodeHealthCheck 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.7.0/pkg/reconcile

func (*NodeHealthCheckReconciler) SetupWithManager

func (r *NodeHealthCheckReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.

Jump to

Keyboard shortcuts

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