route

package
v0.0.0-...-0120ab8 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRouteSyncController

func NewRouteSyncController(
	routeName string,
	isHealthCheckEnabled bool,

	configClient configclientv1.ConfigV1Interface,
	configInformer configinformer.SharedInformerFactory,

	operatorClient v1helpers.OperatorClient,
	routev1Client routeclientv1.RoutesGetter,
	secretClient coreclientv1.SecretsGetter,

	operatorConfigInformer v1.ConsoleInformer,
	secretInformer coreinformersv1.SecretInformer,
	routeInformer routesinformersv1.RouteInformer,

	recorder events.Recorder,
) factory.Controller

func ValidateCustomCertSecret

func ValidateCustomCertSecret(customCertSecret *corev1.Secret) (*routesub.CustomTLSCert, error)

Validate secret that holds custom TLS certificate and key. Secret has to contain `tls.crt` and `tls.key` data keys where the certificate and key are stored and both need to be in valid format. Return the custom TLS certificate and key

Types

type RouteSyncController

type RouteSyncController struct {
	// contains filtered or unexported fields
}

func (*RouteSyncController) GetCustomRouteTLSSecret

func (c *RouteSyncController) GetCustomRouteTLSSecret(ctx context.Context, routeConfig *routesub.RouteConfig) (*corev1.Secret, error)

func (*RouteSyncController) GetDefaultRouteTLSSecret

func (c *RouteSyncController) GetDefaultRouteTLSSecret(ctx context.Context, routeConfig *routesub.RouteConfig) (*corev1.Secret, error)

func (*RouteSyncController) Sync

func (c *RouteSyncController) Sync(ctx context.Context, controllerContext factory.SyncContext) error

func (*RouteSyncController) SyncCustomRoute

func (c *RouteSyncController) SyncCustomRoute(ctx context.Context, routeConfig *routesub.RouteConfig, controllerContext factory.SyncContext) (*routev1.Route, string, error)

Custom route sync needs to: 1. validate if the reference for secret with TLS certificate and key is defined in operator config(in case a non-openshift cluster domain is used) 2. if secret is defined, verify the TLS certificate and key 4. create the custom console route, if custom TLS certificate and key are defined use them 5. apply the custom route

func (*RouteSyncController) SyncDefaultRoute

func (c *RouteSyncController) SyncDefaultRoute(ctx context.Context, routeConfig *routesub.RouteConfig, ingressConfig *configv1.Ingress, controllerContext factory.SyncContext) (*routev1.Route, string, error)

func (*RouteSyncController) ValidateCustomRouteConfig

func (c *RouteSyncController) ValidateCustomRouteConfig(ctx context.Context, routeConfig *routesub.RouteConfig) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL