balancer

package
v0.0.0-...-37b7bf9 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(manager manager.Manager) error

Add creates a newly registered balancer-controller to controller-manager.

func ConfigMapHash

func ConfigMapHash(cm *corev1.ConfigMap) string

func ConfigMapName

func ConfigMapName(balancer *exposerv1alpha1.Balancer) string

func DeploymentName

func DeploymentName(balancer *exposerv1alpha1.Balancer) string

func NewConfigMap

func NewConfigMap(balancer *exposerv1alpha1.Balancer) (*corev1.ConfigMap, error)

NewConfigMap creates a new configmap for the input Balancer instance.

func NewDeployment

func NewDeployment(balancer *exposerv1alpha1.Balancer) (*appv1.Deployment, error)

NewDeployment creates a new deployment (which controls one nginx pod) for the Balancer.

func NewFrontendService

func NewFrontendService(balancer *exposerv1alpha1.Balancer) (*corev1.Service, error)

NewFrontendService creates a new front-end Service for handling all requests incoming. All the incoming requests will be forwarded to backend services by the nginx instance.

func NewPodLabels

func NewPodLabels(balancer *exposerv1alpha1.Balancer) map[string]string

func NewServiceLabels

func NewServiceLabels(balancer *exposerv1alpha1.Balancer) map[string]string

Types

type ReconcilerBalancer

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

ReconcilerBalancer reconciles a Balancer instance. Reconciler is the core of a controller.

func (*ReconcilerBalancer) Reconcile

func (r *ReconcilerBalancer) Reconcile(context context.Context, request reconcile.Request) (reconcile.Result, error)

Reconcile reads the status of the Balancer object and makes changes toward to Balancer.Spec. This func must be implemented to be a legal reconcile.Reconciler!

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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