controller

package
v0.12.11 Latest Latest
Warning

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

Go to latest
Published: Dec 25, 2021 License: Apache-2.0 Imports: 40 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Client       clientset.Interface
	MasterSocket string

	RateLimitUpdate  float32
	ResyncPeriod     time.Duration
	WaitBeforeUpdate time.Duration

	DefaultService           string
	IngressClass             string
	ControllerName           string
	WatchIngressWithoutClass bool
	WatchNamespace           string
	ConfigMapName            string

	ForceNamespaceIsolation bool
	WaitBeforeShutdown      int
	AllowCrossNamespace     bool
	DisableNodeList         bool
	DisablePodList          bool
	DisableExternalName     bool
	DisableConfigKeywords   string
	AnnPrefix               string

	AcmeServer              bool
	AcmeCheckPeriod         time.Duration
	AcmeFailInitialDuration time.Duration
	AcmeFailMaxDuration     time.Duration
	AcmeElectionID          string
	AcmeSecretKeyName       string
	AcmeTokenConfigmapName  string
	AcmeTrackTLSAnn         bool

	BucketsResponseTime []float64

	TCPConfigMapName       string
	DefaultSSLCertificate  string
	VerifyHostname         bool
	DefaultHealthzURL      string
	StatsCollectProcPeriod time.Duration
	PublishService         string
	Backend                ingress.Controller

	UpdateStatus           bool
	UseNodeInternalIP      bool
	ElectionID             string
	UpdateStatusOnShutdown bool

	BackendShards   int
	SortEndpointsBy string
}

Configuration contains all the settings required by an Ingress controller

type GenericController

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

GenericController holds the boilerplate code required to build an Ingress controlller.

func NewIngressController

func NewIngressController(backend ingress.Controller) *GenericController

NewIngressController returns a configured Ingress controller

func (*GenericController) CreateDefaultSSLCertificate added in v0.8.1

func (ic *GenericController) CreateDefaultSSLCertificate() (path, hash string, crt *x509.Certificate)

CreateDefaultSSLCertificate ...

func (GenericController) DeleteSecret added in v0.11.1

func (ic GenericController) DeleteSecret(key string)

DeleteSecret ...

func (*GenericController) GetCertificate added in v0.7.1

func (ic *GenericController) GetCertificate(namespace, secretName string) (*ingress.SSLCert, error)

GetCertificate get a SSLCert object from a secret name

func (*GenericController) GetConfig added in v0.8.1

func (ic *GenericController) GetConfig() *Configuration

GetConfig expose the controller configuration

func (GenericController) GetFullResourceName

func (ic GenericController) GetFullResourceName(name, currentNamespace string) string

GetFullResourceName add the currentNamespace prefix if name doesn't provide one and AllowCrossNamespace is allowing this

func (*GenericController) GetStopCh added in v0.9.1

func (ic *GenericController) GetStopCh() chan struct{}

GetStopCh ...

func (GenericController) Info

Info returns information about the backend

func (*GenericController) SetNewCtrl added in v0.11.1

func (ic *GenericController) SetNewCtrl(newctrl NewCtrlIntf)

SetNewCtrl ...

func (*GenericController) StartAsync added in v0.11.1

func (ic *GenericController) StartAsync()

StartAsync starts the Ingress controller.

func (GenericController) Stop

func (ic GenericController) Stop() error

Stop stops the loadbalancer controller.

func (*GenericController) SyncSecret added in v0.11.1

func (ic *GenericController) SyncSecret(key string)

SyncSecret keeps in sync Secrets used by Ingress rules with the files on disk to allow copy of the content of the secret to disk to be used by external processes.

func (GenericController) UpdateSecret added in v0.11.1

func (ic GenericController) UpdateSecret(key string)

UpdateSecret ...

type NewCtrlIntf added in v0.11.1

type NewCtrlIntf interface {
	GetIngressList() ([]*networking.Ingress, error)
	GetSecret(name string) (*apiv1.Secret, error)
	IsValidClass(ing *networking.Ingress) bool
}

NewCtrlIntf is a temporary interface used by this generic and now deprecated controller to call functionality moved to the new controller.

type StatusSync added in v0.10.1

type StatusSync interface {
	Run(stopCh <-chan struct{})
	Shutdown()
}

StatusSync ...

func NewStatusSyncer added in v0.10.1

func NewStatusSyncer(ic *GenericController) StatusSync

NewStatusSyncer returns a new Sync instance

Jump to

Keyboard shortcuts

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