Documentation ¶
Index ¶
- Variables
- func AddAllFlags(fs *pflag.FlagSet, f ...Flagger)
- func AddAllToManager(mgr manager.Manager, all ...AddToMangerFunc) error
- func AddToTargetScheme(scheme *runtime.Scheme) error
- func CompleteAll(c ...Completer) error
- type AddToMangerFunc
- type Completer
- type Flagger
- type ManagerConfig
- type ManagerOptions
- type Option
- type ProfilingOptions
- type SourceClientConfig
- type SourceClientOptions
- type TargetClusterConfig
- type TargetClusterOptions
Constants ¶
This section is empty.
Variables ¶
var ( // AddToSourceScheme registers all API types in the given scheme that resource-manager expects to be in the source // cluster scheme (the Manager's scheme). AddToSourceScheme = sourceSchemeBuilder.AddToScheme )
Functions ¶
func AddAllFlags ¶
AddAllFlags adds all Flaggers to the given FlagSet.
func AddAllToManager ¶
func AddAllToManager(mgr manager.Manager, all ...AddToMangerFunc) error
AddAllToManager calls all AddToManagerFuncs.
func AddToTargetScheme ¶ added in v1.42.0
AddToTargetScheme registers all API types in the given scheme that resource-manager expects to be in the target cluster scheme (the Cluster that ManagedResources are applied to).
Types ¶
type AddToMangerFunc ¶
AddToMangerFunc is a function which will add a controller or something similar to a Manager.
type Completer ¶
type Completer interface {
Complete() error
}
Completer can complete some configuration options.
type ManagerConfig ¶
type ManagerConfig struct {
// contains filtered or unexported fields
}
ManagerConfig contains the completed general manager configuration which can be applied to manager.Options via Apply.
func (*ManagerConfig) Apply ¶
func (c *ManagerConfig) Apply(opts *manager.Options)
Apply sets the values of this ManagerConfig on the given manager.Options.
type ManagerOptions ¶
type ManagerOptions struct {
// contains filtered or unexported fields
}
ManagerOptions contains options needed to construct the controller-runtime manager.
func (*ManagerOptions) AddFlags ¶
func (o *ManagerOptions) AddFlags(fs *pflag.FlagSet)
AddFlags adds the needed command line flags to the given FlagSet.
func (*ManagerOptions) Complete ¶
func (o *ManagerOptions) Complete() error
Complete builds the manager.Options based on the given flag values.
func (*ManagerOptions) Completed ¶
func (o *ManagerOptions) Completed() *ManagerConfig
Completed returns the constructed ManagerConfig.
type ProfilingOptions ¶ added in v1.44.0
type ProfilingOptions struct { // EnableProfiling enables profiling via web interface host:port/debug/pprof/. EnableProfiling bool // EnableContentionProfiling enable lock contention profiling, if profiling is enabled EnableContentionProfiling bool }
ProfilingOptions contains options needed to enable profiling.
func (*ProfilingOptions) AddFlags ¶ added in v1.44.0
func (p *ProfilingOptions) AddFlags(fs *pflag.FlagSet)
AddFlags adds the needed command line flags to the given FlagSet.
type SourceClientConfig ¶
type SourceClientConfig struct { RESTConfig *rest.Config CacheResyncPeriod *time.Duration ClientSet *kubernetes.Clientset Scheme *runtime.Scheme Namespace string }
SourceClientConfig contains the constructed source clients including a kubernetes ClientSet and Scheme.
func (*SourceClientConfig) ApplyClientSet ¶
func (c *SourceClientConfig) ApplyClientSet(clientSet *kubernetes.Clientset)
ApplyClientSet sets clientSet to the ClientSet of this config.
func (*SourceClientConfig) ApplyManagerOptions ¶
func (c *SourceClientConfig) ApplyManagerOptions(opts *manager.Options)
ApplyManagerOptions sets the values of this SourceClientConfig on the given manager.Options.
type SourceClientOptions ¶
type SourceClientOptions struct {
// contains filtered or unexported fields
}
SourceClientOptions contains options needed to construct the source client.
func (*SourceClientOptions) AddFlags ¶
func (o *SourceClientOptions) AddFlags(fs *pflag.FlagSet)
AddFlags adds the needed command line flags to the given FlagSet.
func (*SourceClientOptions) Complete ¶
func (o *SourceClientOptions) Complete() error
Complete builds the source client based on the given flag values and saves it for retrieval via Completed.
func (*SourceClientOptions) Completed ¶
func (o *SourceClientOptions) Completed() *SourceClientConfig
Completed returns the constructed source clients including a kubernetes ClientSet and Scheme.
type TargetClusterConfig ¶ added in v1.35.0
TargetClusterConfig contains the constructed target clients including a RESTMapper and Scheme. Before the first usage, Start and WaitForCacheSync should be called to ensure that the cache is running and has been populated successfully.
type TargetClusterOptions ¶ added in v1.35.0
type TargetClusterOptions struct { // Namespace is the namespace in which controllers for the target cluster act on objects (defaults to all namespaces) Namespace string // If RESTConfig is set, don't load the kubeconfig but use the provided config instead (for integration tests). RESTConfig *rest.Config // contains filtered or unexported fields }
TargetClusterOptions contains options needed to construct the target config.
func (*TargetClusterOptions) AddFlags ¶ added in v1.35.0
func (o *TargetClusterOptions) AddFlags(fs *pflag.FlagSet)
AddFlags adds the needed command line flags to the given FlagSet.
func (*TargetClusterOptions) Complete ¶ added in v1.35.0
func (o *TargetClusterOptions) Complete() error
Complete builds the target config based on the given flag values and saves it for retrieval via Completed.
func (*TargetClusterOptions) Completed ¶ added in v1.35.0
func (o *TargetClusterOptions) Completed() *TargetClusterConfig
Completed returns the constructed target clients including a RESTMapper and Scheme. Before the first usage, Start and WaitForCacheSync should be called to ensure that the cache is running and has been populated successfully.