api

package
v1.14.13 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2024 License: Apache-2.0 Imports: 22 Imported by: 1

Documentation

Index

Constants

View Source
const (
	// OperatorAPIServeAddr is the "<ip>:<port>" on which to serve api requests
	// from the operator.
	// Use ":<port>" to bind on all interfaces.
	// Use an empty string to bind on both "127.0.0.1:0" and "[::1]:0".
	OperatorAPIServeAddr = "operator-api-serve-addr"
)
View Source
const (
	// OperatorAPIServeAddrDefault is the default "<ip>:<port>" value on which to serve
	// api requests from the operator.
	OperatorAPIServeAddrDefault = "localhost:9234"
)

Variables

View Source
var MetricsHandlerCell = cell.Module(
	"metrics-handler",
	"Operator metrics HTTP handler",

	cell.Provide(newMetricsHandler),
)
View Source
var ServerCell = cell.Module(
	"cilium-operator-api",
	"Cilium Operator API Server",

	cell.Config(Config{}),
	cell.Provide(newServer),
	cell.Invoke(func(Server) {}),
)

Functions

func HealthHandlerCell

func HealthHandlerCell(
	kvstoreEnabled kvstoreEnabledFunc,
	isOperatorLeading isOperatorLeadingFunc,
) cell.Cell

Types

type Config

type Config struct {
	OperatorAPIServeAddr string
}

func (Config) Flags

func (def Config) Flags(flags *pflag.FlagSet)

type Server

type Server interface {
	// Ports returns the ports at which the server is listening
	Ports() []int
}

Jump to

Keyboard shortcuts

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