commoncmdoptions

package
v0.0.0-...-2d87d23 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2026 License: Apache-2.0 Imports: 27 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Copyright 2026 Red Hat, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var (
	// LeaseDuration is the default duration for the leader election lease.
	LeaseDuration = metav1.Duration{Duration: 137 * time.Second}
	// RenewDeadline is the default duration for the leader renewal.
	RenewDeadline = metav1.Duration{Duration: 107 * time.Second}
	// RetryPeriod is the default duration for the leader election retrial.
	RetryPeriod = metav1.Duration{Duration: 26 * time.Second}
)

The default durations for the leader election operations.

Functions

This section is empty.

Types

type OperatorConfig

type OperatorConfig struct {
	CAPINamespace     *string
	MAPINamespace     *string
	OperatorNamespace *string

	// TLSOptions are the TLS options functions used by the manager.  It
	// defaults to the cluster-wide TLS profile, but can be overridden on the
	// command line. Metrics and webhooks will use these.
	TLSOptions []func(config *tls.Config)
	// contains filtered or unexported fields
}

OperatorConfig contains configuration options common to all CAPI operator managers.

func InitOperatorConfig

func InitOperatorConfig(ctx context.Context, cfg *rest.Config, scheme *runtime.Scheme, managerName, defaultManagerNamespace string, extraFlags *flag.FlagSet) (
	logr.Logger, OperatorConfig, ctrl.Options,
	func(ctx context.Context, cancel context.CancelFunc, mgrOpts ctrl.Options) (ctrl.Manager, error),
	error,
)

InitOperatorConfig configures command line flags for options common to all managers.

Jump to

Keyboard shortcuts

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