Documentation
¶
Index ¶
Constants ¶
View Source
const (
LabelPodSpecHash = "pod-spec-hash"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Operator Operator ScannerAquaCSP ScannerAquaCSP ScannerTrivy ScannerTrivy }
func GetOperatorConfig ¶
type InstallMode ¶
type InstallMode string
InstallMode represents multitenancy support defined by the Operator Lifecycle Manager spec.
const ( InstallModeOwnNamespace InstallMode = "OwnNamespace" InstallModeSingleNamespace InstallMode = "SingleNamespace" InstallModeMultiNamespace InstallMode = "MultiNamespace" InstallModeAllNamespaces InstallMode = "AllNamespaces" )
type Operator ¶
type Operator struct { Namespace string `env:"OPERATOR_NAMESPACE"` TargetNamespaces string `env:"OPERATOR_TARGET_NAMESPACES"` ServiceAccount string `env:"OPERATOR_SERVICE_ACCOUNT" envDefault:"starboard-operator"` ScanJobTimeout time.Duration `env:"OPERATOR_SCAN_JOB_TIMEOUT" envDefault:"5m"` MetricsBindAddress string `env:"OPERATOR_METRICS_BIND_ADDRESS" envDefault:":8080"` HealthProbeBindAddress string `env:"OPERATOR_HEALTH_PROBE_BIND_ADDRESS" envDefault:":9090"` LogDevMode bool `env:"OPERATOR_LOG_DEV_MODE" envDefault:"false"` }
func (Operator) GetInstallMode ¶
func (c Operator) GetInstallMode() (InstallMode, error)
GetInstallMode resolves InstallMode based on configured operator and target namespaces.
func (Operator) GetOperatorNamespace ¶
GetOperatorNamespace returns the namespace the operator should be running in.
func (Operator) GetTargetNamespaces ¶
GetTargetNamespaces returns namespaces the operator should be watching for changes.
type ScannerAquaCSP ¶
type ScannerAquaCSP struct { Enabled bool `env:"OPERATOR_SCANNER_AQUA_CSP_ENABLED" envDefault:"false"` ImageRef string `env:"OPERATOR_SCANNER_AQUA_CSP_IMAGE" envDefault:"aquasec/scanner:5.0"` Host string `env:"OPERATOR_SCANNER_AQUA_CSP_HOST"` Username string `env:"OPERATOR_SCANNER_AQUA_CSP_USERNAME"` Password string `env:"OPERATOR_SCANNER_AQUA_CSP_PASSWORD"` }
type ScannerTrivy ¶
type ScannerTrivy struct { Enabled bool `env:"OPERATOR_SCANNER_TRIVY_ENABLED" envDefault:"true"` ImageRef string `env:"OPERATOR_SCANNER_TRIVY_IMAGE" envDefault:"aquasec/trivy:0.11.0"` }
func (ScannerTrivy) GetTrivyImageRef ¶
func (c ScannerTrivy) GetTrivyImageRef() string
Click to show internal directories.
Click to hide internal directories.