options

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetFlag

func SetFlag(set *sets.Set[string]) pflag.Value

SetFlag wraps a given set so it can be used as a CLI flag.

Types

type ControllerRunOptions

type ControllerRunOptions struct {
	MetricsAddr             string
	HealthAddr              string
	EnableLeaderElection    bool
	LeaderElectionWorkspace string
	LeaderElectionNamespace string
	WorkerCount             int

	EnabledControllers  sets.Set[string]
	DisabledControllers sets.Set[string]
}

func NewDefaultOptions

func NewDefaultOptions(portIndex int) ControllerRunOptions

portIndex is a unique number per cmd/, in order for them to be able to run in parallel during development without having ports clash.

func (*ControllerRunOptions) AddPFlags

func (opts *ControllerRunOptions) AddPFlags(flags *pflag.FlagSet)

func (*ControllerRunOptions) EffectiveControllers

func (opts *ControllerRunOptions) EffectiveControllers(allControllerNames sets.Set[string]) sets.Set[string]

Jump to

Keyboard shortcuts

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