Documentation ¶
Overview ¶
Package app implements a server that runs a set of active components. This includes node controllers, service and route controller, and so on.
Index ¶
- Constants
- Variables
- func CreateControllerContext(s *cloudcontrollerconfig.CompletedConfig, ...) (genericcontrollermanager.ControllerContext, error)
- func GetAvailableResources(clientBuilder clientbuilder.ControllerClientBuilder) (map[schema.GroupVersionResource]bool, error)
- func KnownControllers() []string
- func NewCloudControllerManagerCommand() *cobra.Command
- func ResyncPeriod(c *cloudcontrollerconfig.CompletedConfig) func() time.Duration
- func Run(ctx context.Context, c *cloudcontrollerconfig.CompletedConfig, ...) error
- func RunWrapper(s *options.CloudControllerManagerOptions, c *cloudcontrollerconfig.Config, ...) func(ctx context.Context)
- func StartHTTPServer(c *cloudcontrollerconfig.CompletedConfig, stopCh <-chan struct{}) (*controllerhealthz.MutableHealthzHandler, error)
Constants ¶
const ( // ControllerStartJitter is the jitter value used when starting controller managers. ControllerStartJitter = 1.0 // ConfigzName is the name used for register cloud-controller manager /configz, same with GroupName. ConfigzName = "cloudcontrollermanager.config.k8s.io" )
Variables ¶
var ControllersDisabledByDefault = sets.NewString()
ControllersDisabledByDefault is the controller disabled default when starting cloud-controller managers.
Functions ¶
func CreateControllerContext ¶ added in v1.25.0
func CreateControllerContext(s *cloudcontrollerconfig.CompletedConfig, clientBuilder clientbuilder.ControllerClientBuilder, stop <-chan struct{}) (genericcontrollermanager.ControllerContext, error)
CreateControllerContext creates a context struct containing references to resources needed by the controllers such as the cloud provider and clientBuilder. rootClientBuilder is only used for the shared-informers client and token controller.
func GetAvailableResources ¶ added in v1.25.0
func GetAvailableResources(clientBuilder clientbuilder.ControllerClientBuilder) (map[schema.GroupVersionResource]bool, error)
GetAvailableResources gets the map which contains all available resources of the apiserver TODO: In general, any controller checking this needs to be dynamic so users don't have to restart their controller manager if they change the apiserver. Until we get there, the structure here needs to be exposed for the construction of a proper ControllerContext.
func KnownControllers ¶
func KnownControllers() []string
KnownControllers indicate the default controller we are known.
func NewCloudControllerManagerCommand ¶
NewCloudControllerManagerCommand creates a *cobra.Command object with default parameters
func ResyncPeriod ¶ added in v1.25.0
func ResyncPeriod(c *cloudcontrollerconfig.CompletedConfig) func() time.Duration
ResyncPeriod returns a function which generates a duration each time it is invoked; this is so that multiple controllers don't get into lock-step and all hammer the apiserver with list requests simultaneously.
func Run ¶
func Run(ctx context.Context, c *cloudcontrollerconfig.CompletedConfig, h *controllerhealthz.MutableHealthzHandler) error
Run runs the ExternalCMServer. This should never exit.
func RunWrapper ¶ added in v1.0.0
func RunWrapper(s *options.CloudControllerManagerOptions, c *cloudcontrollerconfig.Config, h *controllerhealthz.MutableHealthzHandler) func(ctx context.Context)
RunWrapper adapts the ccm boot logic to the leader elector call back function
func StartHTTPServer ¶ added in v1.0.0
func StartHTTPServer(c *cloudcontrollerconfig.CompletedConfig, stopCh <-chan struct{}) (*controllerhealthz.MutableHealthzHandler, error)
StartHTTPServer starts the controller manager HTTP server
Types ¶
This section is empty.