flag

package
v0.0.21 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultNameTemplate string = "{{ .WorkloadName }}-{{ .Profile }}-vpa"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	WatchNamespaces     []string       // Namespaces to watch
	MetricsAddr         string         // Address for the metrics server
	LeaderElection      bool           // Enable leader election
	ProbeAddr           string         // Address for health and readiness probes
	SecureMetrics       bool           // Serve metrics over HTTPS
	EnableHTTP2         bool           // Enable HTTP/2 for servers
	EnableMetrics       bool           // Enable or disable metrics
	LogEncoder          string         // Log format: "json" or "console"
	LogStacktraceLevel  string         // Stacktrace log level
	LogDev              bool           // Enable development logging mode
	ProfileAnnotation   string         // Annotation key workloads must set to request a profile.
	ManagedLabel        string         // Label key to mark VPAs as managed by the operator.
	DefaultNameTemplate string         // Template used to render managed VPA names; can be overridden per profile.
	ConfigPath          string         // Path to the Config containing VPA profiles.
	CRDCheck            bool           // Enable the check for the VPA CRD.
	SkipManagerStart    bool           // Skip starting the manager (used by tests).
	OverriddenValues    map[string]any // CLI overrides
}

Options holds all configuration options for the application.

func ParseArgs

func ParseArgs(args []string, version string) (Options, error)

ParseArgs parses CLI flags into Options and handles --help/--version output.

Jump to

Keyboard shortcuts

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