server

package
v0.0.0-...-f4dfa5d Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2024 License: Apache-2.0 Imports: 84 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendNewEncryptionKey

func AppendNewEncryptionKey(keys *[]apiserverconfigv1.Key) error

func HomeKubeConfig

func HomeKubeConfig(write, rootless bool) (string, error)

func ResolveDataDir

func ResolveDataDir(dataDir string) (string, error)

func StartServer

func StartServer(ctx context.Context, config *Config, cfg *cmds.Server) error

Types

type Config

type Config struct {
	DisableAgent      bool
	ControlConfig     config.Control
	SupervisorPort    int
	StartupHooks      []cmds.StartupHook
	LeaderControllers CustomControllers
	Controllers       CustomControllers
}

type Context

type Context struct {
	K3s   *k3s.Factory
	Helm  *helm.Factory
	Batch *batch.Factory
	Apps  *apps.Factory
	Auth  *rbac.Factory
	Core  *core.Factory
	K8s   kubernetes.Interface
	Event record.EventRecorder
}

func NewContext

func NewContext(ctx context.Context, config *Config, forServer bool) (*Context, error)

func (*Context) Start

func (c *Context) Start(ctx context.Context) error

type CustomControllers

type CustomControllers []func(ctx context.Context, sc *Context) error

type EncryptionRequest

type EncryptionRequest struct {
	Stage  *string `json:"stage,omitempty"`
	Enable *bool   `json:"enable,omitempty"`
	Force  bool    `json:"force"`
	Skip   bool    `json:"skip"`
}

type EncryptionState

type EncryptionState struct {
	Stage        string   `json:"stage"`
	ActiveKey    string   `json:"activekey"`
	Enable       *bool    `json:"enable,omitempty"`
	HashMatch    bool     `json:"hashmatch,omitempty"`
	HashError    string   `json:"hasherror,omitempty"`
	InactiveKeys []string `json:"inactivekeys,omitempty"`
}

type TokenRotateRequest

type TokenRotateRequest struct {
	NewToken *string `json:"newToken,omitempty"`
}

Jump to

Keyboard shortcuts

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