Documentation ¶
Index ¶
- type NGINXController
- func (n NGINXController) BackendDefaults() defaults.Backend
- func (n NGINXController) Check(_ *http.Request) error
- func (n *NGINXController) ConfigureFlags(flags *pflag.FlagSet)
- func (n NGINXController) DefaultEndpoint() ingress.Endpoint
- func (n NGINXController) DefaultIngressClass() string
- func (n NGINXController) Info() *ingress.BackendInfo
- func (n NGINXController) Name() string
- func (n *NGINXController) OnUpdate(ingressCfg ingress.Configuration) error
- func (n *NGINXController) OverrideFlags(flags *pflag.FlagSet)
- func (n *NGINXController) SetConfig(cmap *apiv1.ConfigMap)
- func (n *NGINXController) SetListers(lister *ingress.StoreLister)
- func (n *NGINXController) Start()
- func (n *NGINXController) Stop() error
- func (n *NGINXController) UpdateIngressStatus(*extensions.Ingress) []apiv1.LoadBalancerIngress
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NGINXController ¶
type NGINXController struct {
// contains filtered or unexported fields
}
NGINXController ...
func NewNGINXController ¶
func NewNGINXController() *NGINXController
NewNGINXController creates a new NGINX Ingress controller. If the environment variable NGINX_BINARY exists it will be used as source for nginx commands
func (NGINXController) BackendDefaults ¶
func (n NGINXController) BackendDefaults() defaults.Backend
BackendDefaults returns the nginx defaults
func (NGINXController) Check ¶
func (n NGINXController) Check(_ *http.Request) error
Check returns if the nginx healthz endpoint is returning ok (status code 200)
func (*NGINXController) ConfigureFlags ¶
func (n *NGINXController) ConfigureFlags(flags *pflag.FlagSet)
ConfigureFlags allow to configure more flags before the parsing of command line arguments
func (NGINXController) DefaultEndpoint ¶
func (n NGINXController) DefaultEndpoint() ingress.Endpoint
DefaultEndpoint returns the default endpoint to be use as default server that returns 404.
func (NGINXController) DefaultIngressClass ¶
func (n NGINXController) DefaultIngressClass() string
DefaultIngressClass just return the default ingress class
func (NGINXController) Info ¶
func (n NGINXController) Info() *ingress.BackendInfo
Info return build information
func (NGINXController) Name ¶
func (n NGINXController) Name() string
Name returns the healthcheck name
func (*NGINXController) OnUpdate ¶
func (n *NGINXController) OnUpdate(ingressCfg ingress.Configuration) error
OnUpdate is called by syncQueue in https://github.com/kubernetes/ingress-nginx/blob/master/pkg/ingress/controller/controller.go#L426 periodically to keep the configuration in sync.
convert configmap to custom configuration object (different in each implementation) write the custom template (the complexity depends on the implementation) write the configuration file returning nill implies the backend will be reloaded. if an error is returned means requeue the update
func (*NGINXController) OverrideFlags ¶
func (n *NGINXController) OverrideFlags(flags *pflag.FlagSet)
OverrideFlags customize NGINX controller flags
func (*NGINXController) SetConfig ¶
func (n *NGINXController) SetConfig(cmap *apiv1.ConfigMap)
SetConfig sets the configured configmap
func (*NGINXController) SetListers ¶
func (n *NGINXController) SetListers(lister *ingress.StoreLister)
SetListers sets the configured store listers in the generic ingress controller
func (*NGINXController) Start ¶
func (n *NGINXController) Start()
Start start a new NGINX master process running in foreground.
func (*NGINXController) Stop ¶
func (n *NGINXController) Stop() error
Stop gracefully stops the NGINX master process.
func (*NGINXController) UpdateIngressStatus ¶
func (n *NGINXController) UpdateIngressStatus(*extensions.Ingress) []apiv1.LoadBalancerIngress
UpdateIngressStatus custom Ingress status update