tool

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoNamespace = fmt.Errorf("namespace not found for current environment")

ErrNoNamespace indicates that a namespace could not be found for the current environment

View Source
var ErrRunLocal = fmt.Errorf("operator run mode forced to local")

ErrRunLocal indicates that the operator is set to run in local mode (this error is returned by functions that only work on operators running in cluster mode)

View Source
var Options = SyncerOptions{}

Options default value

Functions

func GetOperatorNamespace

func GetOperatorNamespace() (string, error)

GetOperatorNamespace returns the namespace the operator should be running in.

func ProcessFlags

func ProcessFlags()

ProcessFlags parses command line parameters into Options

Types

type RunModeType

type RunModeType string
const (
	ForceRunModeEnv             = "OSDK_FORCE_RUN_MODE"
	LocalRunMode    RunModeType = "local"
	ClusterRunMode  RunModeType = "cluster"
)

type SyncerOptions

type SyncerOptions struct {
	ClusterNamespaceOnHub     string
	HubConfigFilePathName     string
	ManagedConfigFilePathName string
	DisableSpecSync           bool
	DisableGkSync             bool
	EnableLease               bool
	EnableLeaderElection      bool
	ProbeAddr                 string
	MetricsAddr               string
	SecureMetrics             bool
	// The namespace that the replicated policies should be synced to. This defaults to the same namespace as on the
	// Hub.
	ClusterNamespace      string
	DeploymentName        string
	EvaluationConcurrency uint8
	ClientQPS             float32
	ClientBurst           uint32
	ComplianceAPIURL      string
}

PolicySpecSyncOptions for command line flag parsing

Jump to

Keyboard shortcuts

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