controllers

package
v0.0.0-...-f2e105f Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2022 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// InjectLabelKey is the label which indicates that the Service CA
	// certificate should be injected into the ConfigMap
	InjectLabelKey = "service.syn.tools/inject-ca-bundle"
)
View Source
const (
	// ServingCertLabelKey is the label key which the controller reacts to
	// to create a secret. The label value is used as the secret name
	// for the generated Certificate.
	ServingCertLabelKey = "service.syn.tools/serving-cert-secret-name"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigMapReconciler

type ConfigMapReconciler struct {
	client.Client
	Scheme      *runtime.Scheme
	CANamespace string
}

ConfigMapReconciler injects the service CA certificate into field `ca.crt` of ConfigMap objects which have the label `service.syn.tools/inject-ca-bundle` set to `true`.

func (*ConfigMapReconciler) Reconcile

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

Reconcile injects the service CA certificate into ConfigMaps which have the `service.syn.tools/inject-ca-bundle` label set to `true`. Please note that the reconciler will requeue requests until the Service CA is created an ready.

func (*ConfigMapReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type ServiceReconciler

type ServiceReconciler struct {
	client.Client
	Scheme      *runtime.Scheme
	CANamespace string
}

ServiceReconciler reconcile Service objects which have the label `service.syn.tools/serving-cert-secret-name` set.

func (*ServiceReconciler) Reconcile

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

Reconcile creates or updates a cert-manager Certificate resource for services which have label `service.syn.tools/serving-cert-secret-name` set. The Certificate resource is configured to use the Service CA cluster issuer, and the value of the `service.syn.tools/serving-cert-secret-name` label is used as the certificate secret name. Please note that the reconciler will requeue requests until the Service CA is created an ready.

func (*ServiceReconciler) SetupWithManager

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