options

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2026 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	KCPAPIResourceSchemaSource     = SchemaSource("APIResourceSchema.v1alpha1.apis.kcp.io")
	CustomResourceDefinitionSource = SchemaSource("CustomResourceDefinition.v1.apiextensions.k8s.io")
)

Functions

This section is empty.

Types

type CompletedOptions

type CompletedOptions struct {
	// contains filtered or unexported fields
}

func (*CompletedOptions) Validate

func (options *CompletedOptions) Validate() error
type Cookie struct {
	SigningKey    string
	EncryptionKey string
}

func NewCookie

func NewCookie() *Cookie

func (*Cookie) AddFlags

func (options *Cookie) AddFlags(fs *pflag.FlagSet)

func (*Cookie) Complete

func (options *Cookie) Complete() error

func (*Cookie) Validate

func (options *Cookie) Validate() error

type ExtraOptions

type ExtraOptions struct {
	KubeConfig string

	Provider string

	NamespacePrefix       string
	PrettyName            string
	ConsumerScope         string
	Isolation             string
	ExternalAddress       string
	ExternalCAFile        string
	ExternalCA            []byte
	TLSExternalServerName string
	// Defines the source of the schema for the bind screen.
	// Options are:
	// CustomResourceDefinition.v1.apiextensions.k8s.io
	// APIResourceSchema.v1alpha1.apis.kcp.io
	SchemaSource string

	TestingAutoSelect         string
	TestingSkipNameValidation bool

	// If ControllerFrontend starts with http:// it is treated as a URL to a SPA server
	// Else - it is treated as a path to static files to be served.
	Frontend string
	// FrontendDisabled indicates that no frontend should be served at all, including oidc and api.
	// This is useful for backend-only deployments.
	FrontendDisabled bool

	TokenExpiry time.Duration
}

type OIDC

type OIDC struct {
	Type               string
	IssuerClientID     string
	IssuerClientSecret string
	IssuerURL          string
	CallbackURL        string
	AuthorizeURL       string
	CAFile             string

	// TLSConfig is set if an embedded OIDC server is used.
	TLSConfig  *tls.Config
	OIDCServer *oidc.Server

	// AllowedGroups is a list of groups allowed to access bindings inside the cluster
	AllowedGroups []string
	// AllowedUsers is a list of users allowed to access bindings inside the cluster
	AllowedUsers []string
}

func NewOIDC

func NewOIDC() *OIDC

func (*OIDC) AddFlags

func (options *OIDC) AddFlags(fs *pflag.FlagSet)

func (*OIDC) Complete

func (options *OIDC) Complete(listener net.Listener) error

func (*OIDC) Validate

func (options *OIDC) Validate() error

type Options

type Options struct {
	Logs   *logs.Options
	OIDC   *OIDC
	Cookie *Cookie
	Serve  *Serve

	ProviderKcp *providerkcp.Options

	ExtraOptions
}

func NewOptions

func NewOptions() *Options

func (*Options) AddFlags

func (options *Options) AddFlags(fs *pflag.FlagSet)

func (*Options) Complete

func (options *Options) Complete() (*CompletedOptions, error)

type SchemaSource

type SchemaSource string

func (SchemaSource) String

func (s SchemaSource) String() string

type Serve

type Serve struct {
	ListenIP          string
	ListenPort        int
	ListenAddress     string
	CertFile, KeyFile string

	// Listener is used to pre-wire a port zero listener for testing.
	Listener net.Listener
}

func NewServe

func NewServe() *Serve

func (*Serve) AddFlags

func (options *Serve) AddFlags(fs *pflag.FlagSet)

func (*Serve) Complete

func (options *Serve) Complete() error

func (*Serve) Validate

func (options *Serve) Validate() error

Jump to

Keyboard shortcuts

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