controllers

package
v0.0.0-...-126b459 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2023 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MutateDeployment

func MutateDeployment(instance *sentinelv1alpha1.Dashboard, deploy *appsv1.Deployment)

func MutateService

func MutateService(instance *sentinelv1alpha1.Dashboard, svc *corev1.Service)

Types

type DashboardReconciler

type DashboardReconciler struct {
	client.Client
	Scheme     *runtime.Scheme
	RestConfig *rest.Config
	Recorder   record.EventRecorder
}

DashboardReconciler reconciles a Dashboard object

func (*DashboardReconciler) GetHealth

func (r *DashboardReconciler) GetHealth(ctx context.Context, instance *sentinelv1alpha1.Dashboard) error

func (*DashboardReconciler) Reconcile

func (r *DashboardReconciler) 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 Dashboard 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.13.0/pkg/reconcile

func (*DashboardReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

func (*DashboardReconciler) UpdateAppliedStatus

func (r *DashboardReconciler) UpdateAppliedStatus(ctx context.Context, instance *sentinelv1alpha1.Dashboard) error

func (*DashboardReconciler) UpdateCondition

func (r *DashboardReconciler) UpdateCondition(ctx context.Context, instance *sentinelv1alpha1.Dashboard,
	conditionType sentinelv1alpha1.DashboardConditionType, status metav1.ConditionStatus, reasons ...string) error

func (*DashboardReconciler) UpdateReadyStatus

func (r *DashboardReconciler) UpdateReadyStatus(ctx context.Context, instance *sentinelv1alpha1.Dashboard) error

func (*DashboardReconciler) UpdateStatus

func (r *DashboardReconciler) UpdateStatus(ctx context.Context, instance *sentinelv1alpha1.Dashboard) error

Jump to

Keyboard shortcuts

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