controller

package
v0.14.6 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2024 License: Apache-2.0 Imports: 47 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       types.Client
	MasterWorker bool
	MasterSocket string

	RateLimitUpdate  float32
	ReloadInterval   time.Duration
	ResyncPeriod     time.Duration
	WaitBeforeUpdate time.Duration

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

	ReloadStrategy    string
	MaxOldConfigFiles int
	ValidateConfig    bool
	LocalFSPrefix     string

	ForceNamespaceIsolation bool
	WaitBeforeShutdown      int
	AllowCrossNamespace     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
	TrackOldInstances      bool
	Backend                ingress.Controller

	UpdateStatus           bool
	UseNodeInternalIP      bool
	ElectionID             string
	UpdateStatusOnShutdown bool

	BackendShards           int
	SortEndpointsBy         string
	EnableEndpointSlicesAPI bool
}

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 controller.

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) 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