controller

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2026 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ConditionTypeReady indicates the cluster is fully operational
	ConditionTypeReady = "Ready"
	// ConditionTypeCertificatesReady indicates TLS certificates are ready
	ConditionTypeCertificatesReady = "CertificatesReady"
	// ConditionTypeConfigApplied indicates configuration was applied to pods
	ConditionTypeConfigApplied = "ConfigApplied"
)

Condition types for Cluster status

View Source
const (
	// PipelineConditionTypeReady indicates the pipeline is active and has resources
	PipelineConditionTypeReady = "Ready"
	// PipelineConditionTypeResourcesResolved indicates all resources were resolved
	PipelineConditionTypeResourcesResolved = "ResourcesResolved"
)

Condition types for Pipeline status

View Source
const (
	// Labels
	LabelClusterName  = "operator.gnmic.dev/cluster"
	LabelOutputName   = "operator.gnmic.dev/output"
	LabelPipelineName = "operator.gnmic.dev/pipeline"
	LabelPodName      = "operator.gnmic.dev/pod-name"

	LabelValueName      = "gnmic"
	LabelValueManagedBy = "gnmic-operator"

	LabelServiceType                      = "operator.gnmic.dev/service-type"
	LabelValueServiceTypeTunnel           = "tunnel"
	LabelValueServiceTypePrometheusOutput = "prometheus-output"
	LabelValueServiceTypeHeadless         = "rest-api"

	LabelOutputType                = "operator.gnmic.dev/output-type"
	LabelValueOutputTypePrometheus = "prometheus-output"

	LabelCertType            = "operator.gnmic.dev/cert-type"
	LabelValueCertTypeClient = "client"
	LabelValueCertTypeTunnel = "tunnel"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterReconciler

type ClusterReconciler struct {
	client.Client
	Scheme *runtime.Scheme
}

ClusterReconciler reconciles a Cluster object

func (*ClusterReconciler) FetchCredentials

func (r *ClusterReconciler) FetchCredentials(namespace, secretRef string) (*gnmic.Credentials, error)

fetchCredentials fetches credentials from a secret

func (*ClusterReconciler) Reconcile

func (r *ClusterReconciler) 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.

func (*ClusterReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type PipelineReconciler

type PipelineReconciler struct {
	client.Client
	Scheme *runtime.Scheme
}

PipelineReconciler reconciles a Pipeline object

func (*PipelineReconciler) Reconcile

func (r *PipelineReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile validates the Pipeline and updates its status. The actual configuration building happens in the ClusterReconciler which watches Pipelines.

func (*PipelineReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type TargetSourceReconciler

type TargetSourceReconciler struct {
	client.Client
	Scheme *runtime.Scheme
}

TargetSourceReconciler reconciles a TargetSource object

func (*TargetSourceReconciler) Reconcile

func (r *TargetSourceReconciler) 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.

func (*TargetSourceReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type TunnelTargetPolicyReconciler

type TunnelTargetPolicyReconciler struct {
	client.Client
	Scheme *runtime.Scheme
}

TunnelTargetPolicyReconciler reconciles a TunnelTargetPolicy object

func (*TunnelTargetPolicyReconciler) 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 TunnelTargetPolicy 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.22.4/pkg/reconcile

func (*TunnelTargetPolicyReconciler) SetupWithManager

func (r *TunnelTargetPolicyReconciler) 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