controllers

package
v0.11.1 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 66 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FetchGitRepositoryFromProjectInventory added in v0.2.0

func FetchGitRepositoryFromProjectInventory(project *projectv1.Project) (string, string, error)

FetchGitRepositoryFromProjectInventory looks for the GitRepository in the project's inventory. There should ever only be one.

func FetchValuesFileContent added in v0.2.0

func FetchValuesFileContent(ctx context.Context, productName string, artifact *v1.Artifact) (_ []byte, err error)

FetchValuesFileContent takes a product name and a GitRepository artifact to fetch a values file if it exists.

func GetProjectFromObjectNamespace added in v0.5.0

func GetProjectFromObjectNamespace(ctx context.Context, c client.Client, obj client.Object, defaultNamespace string) (*v1alpha1.Project, error)

GetProjectFromObjectNamespace returns the Project from the annotation of the current namespace that an object is in.

Types

type ComponentSubscriptionVersionChangedPredicate added in v0.2.0

type ComponentSubscriptionVersionChangedPredicate struct {
	predicate.Funcs
}

ComponentSubscriptionVersionChangedPredicate watches a subscription for reconciled version changes.

func (ComponentSubscriptionVersionChangedPredicate) Update added in v0.2.0

Update will check the new subscription has a new LastAppliedVersion. If yes, it will trigger a reconcile event.

type ProductDeploymentGeneratorReconciler

type ProductDeploymentGeneratorReconciler struct {
	client.Client
	Scheme *runtime.Scheme

	OCMClient           mpasocm.Contract
	SnapshotWriter      snapshot.Writer
	MpasSystemNamespace string
	EventRecorder       record.EventRecorder
}

ProductDeploymentGeneratorReconciler reconciles a ProductDeploymentGenerator object.

func (*ProductDeploymentGeneratorReconciler) Reconcile

func (r *ProductDeploymentGeneratorReconciler) Reconcile(ctx context.Context, req ctrl.Request) (result ctrl.Result, err 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 (*ProductDeploymentGeneratorReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type ProductDeploymentPipelineReconciler

type ProductDeploymentPipelineReconciler struct {
	client.Client
	Scheme              *runtime.Scheme
	OCMClient           mpasocm.Contract
	MpasSystemNamespace string
	EventRecorder       record.EventRecorder
}

ProductDeploymentPipelineReconciler reconciles a ProductDeploymentPipeline object.

func (*ProductDeploymentPipelineReconciler) Reconcile

func (r *ProductDeploymentPipelineReconciler) Reconcile(ctx context.Context, req ctrl.Request) (result ctrl.Result, err 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 (*ProductDeploymentPipelineReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type ProductDeploymentPipelineScheduler

type ProductDeploymentPipelineScheduler struct {
	client.Client
	Scheme              *runtime.Scheme
	MpasSystemNamespace string

	Deployer      deployers.Deployer
	EventRecorder record.EventRecorder
}

ProductDeploymentPipelineScheduler reconciles a ProductDeploymentPipeline object and schedules them.

func (*ProductDeploymentPipelineScheduler) Reconcile

func (r *ProductDeploymentPipelineScheduler) Reconcile(ctx context.Context, req ctrl.Request) (result ctrl.Result, err 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 (*ProductDeploymentPipelineScheduler) SelectTarget

SelectTarget selects a target based on the provided filtering options.

func (*ProductDeploymentPipelineScheduler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type ProductDeploymentReconciler

type ProductDeploymentReconciler struct {
	client.Client
	Scheme              *runtime.Scheme
	EventRecorder       record.EventRecorder
	MpasSystemNamespace string
}

ProductDeploymentReconciler reconciles a ProductDeployment object.

func (*ProductDeploymentReconciler) Reconcile

func (r *ProductDeploymentReconciler) Reconcile(ctx context.Context, req ctrl.Request) (result ctrl.Result, err 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. Named return values: It's used for improving readability when dealing with the defer patch statement.

func (*ProductDeploymentReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type TargetReconciler added in v0.6.0

type TargetReconciler struct {
	client.Client
	Scheme *runtime.Scheme
	kuberecorder.EventRecorder
	ControllerName string
	// contains filtered or unexported fields
}

TargetReconciler reconciles a Target object.

func (*TargetReconciler) Reconcile added in v0.6.0

func (r *TargetReconciler) Reconcile(ctx context.Context, req ctrl.Request) (_ ctrl.Result, retErr 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. Named return values: It's used for improving readability when dealing with the defer patch statement.

func (*TargetReconciler) SetupWithManager added in v0.6.0

func (r *TargetReconciler) SetupWithManager(_ context.Context, mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.

type ValidationReconciler added in v0.2.0

type ValidationReconciler struct {
	client.Client
	Scheme        *runtime.Scheme
	EventRecorder record.EventRecorder

	MpasSystemNamespace string
	Validator           validators.Validator
}

ValidationReconciler reconciles a Validation object.

func (*ValidationReconciler) Reconcile added in v0.2.0

func (r *ValidationReconciler) Reconcile(ctx context.Context, req ctrl.Request) (_ ctrl.Result, err 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 (*ValidationReconciler) SetupWithManager added in v0.2.0

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