cerebro

package
v0.0.0-...-31fc70c Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: MIT Imports: 38 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ConfigmapCondition shared.ConditionName = "ConfigmapReady"
	ConfigmapPhase     shared.PhaseName     = "Configmap"
)
View Source
const (
	DeploymentCondition shared.ConditionName = "DeploymentReady"
	DeploymentPhase     shared.PhaseName     = "Deployment"
)
View Source
const (
	IngressCondition shared.ConditionName = "IngressReady"
	IngressPhase     shared.PhaseName     = "Ingress"
)
View Source
const (
	LoadBalancerCondition shared.ConditionName = "LoadBalancerReady"
	LoadBalancerPhase     shared.PhaseName     = "LoadBalancer"
)
View Source
const (
	ApplicationSecretCondition shared.ConditionName = "ApplicationSecretReady"
	ApplicationSecretPhase     shared.PhaseName     = "ApplicationSecret"
)
View Source
const (
	ServiceCondition shared.ConditionName = "ServiceReady"
	ServicePhase     shared.PhaseName     = "Service"
)

Variables

This section is empty.

Functions

func GetConfigMapName

func GetConfigMapName(cb *cerebrocrd.Cerebro) (configMapName string)

GetConfigMapName permit to get the configMap name that store the config

func GetContainerImage

func GetContainerImage(cb *cerebrocrd.Cerebro) string

GetContainerImage permit to get the image name

func GetDeploymentName

func GetDeploymentName(cb *cerebrocrd.Cerebro) (name string)

GetDeploymentName permit to get the deployement name

func GetIngressName

func GetIngressName(cb *cerebrocrd.Cerebro) (ingressName string)

GetIngressName permit to get the ingress name

func GetLoadBalancerName

func GetLoadBalancerName(cb *cerebrocrd.Cerebro) (serviceName string)

GetLoadBalancerName permit to get the load balancer name

func GetSecretNameForApplication

func GetSecretNameForApplication(cb *cerebrocrd.Cerebro) (secretName string)

GetSecretNameForApplication permit to get the secret name for application

func GetServiceName

func GetServiceName(cb *cerebrocrd.Cerebro) (serviceName string)

GetServiceName permit to get the service name

func NewCerebroReconciler

func NewCerebroReconciler(client client.Client, logger *logrus.Entry, recorder record.EventRecorder) (multiPhaseReconciler controller.Controller)

Types

type CerebroReconciler

type CerebroReconciler struct {
	controller.Controller
	controller.MultiPhaseReconcilerAction
	controller.MultiPhaseReconciler
	controller.BaseReconciler
	// contains filtered or unexported fields
}

CerebroReconciler reconciles a Cerebro objectFHost

func (*CerebroReconciler) Delete

func (h *CerebroReconciler) Delete(ctx context.Context, o object.MultiPhaseObject, data map[string]any) (err error)

func (*CerebroReconciler) OnError

func (h *CerebroReconciler) OnError(ctx context.Context, o object.MultiPhaseObject, data map[string]any, currentErr error) (res ctrl.Result, err error)

func (*CerebroReconciler) OnSuccess

func (h *CerebroReconciler) OnSuccess(ctx context.Context, r object.MultiPhaseObject, data map[string]any) (res ctrl.Result, err error)

func (*CerebroReconciler) Reconcile

func (r *CerebroReconciler) 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 Cerebro 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 (*CerebroReconciler) SetupWithManager

func (h *CerebroReconciler) 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