controllers

package
v0.6.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	ControllerName = "mpas-project-controller"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ProjectReconciler

type ProjectReconciler struct {
	client.Client
	Scheme                *runtime.Scheme
	ClusterRoleName       string
	Prefix                string
	DefaultCommitTemplate mpasv1alpha1.CommitTemplate
	DefaultNamespace      string
	IssuerName            string
	RegistryAddr          string
}

ProjectReconciler reconciles a Project object.

func (*ProjectReconciler) Reconcile

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

func (*ProjectReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type SecretAnnotationExistsPredicate added in v0.3.0

type SecretAnnotationExistsPredicate struct {
	predicate.Funcs
}

SecretAnnotationExistsPredicate watches a subscription for reconciled version changes.

func (SecretAnnotationExistsPredicate) Create added in v0.3.0

Create will check if the secret contains the managed annotation.

func (SecretAnnotationExistsPredicate) Delete added in v0.3.0

Delete will make sure we don't remove anything that doesn't have the right mpas annotation.

func (SecretAnnotationExistsPredicate) Update added in v0.3.0

Update will check if the new secret contains the managed annotation.

type SecretsReconciler added in v0.3.0

type SecretsReconciler struct {
	client.Client
	kuberecorder.EventRecorder

	Scheme           *runtime.Scheme
	DefaultNamespace string
}

SecretsReconciler reconciles a Secret object.

func (*SecretsReconciler) GetProjectFromObjectNamespace added in v0.3.0

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

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

func (*SecretsReconciler) Reconcile added in v0.3.0

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

func (*SecretsReconciler) SetupWithManager added in v0.3.0

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