config

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EtcdExposeMetrics = "etcd-expose-metrics"
)

Variables

View Source
var (
	RuntimeRKE2    Runtime = "rke2"
	RuntimeK3S     Runtime = "k3s"
	RuntimeUnknown Runtime = "unknown"

	ClusterInitRole Role = "cluster-init"
	ServerRole      Role = "server"
	AgentRole       Role = "agent"
)

Functions

This section is empty.

Types

type Config

type Config struct {
	RuntimeConfig
	KubernetesVersion    string `json:"kubernetesVersion,omitempty"`
	LLMOSOperatorVersion string `json:"llmosOperatorVersion,omitempty"`
	ChartRepo            string `json:"chartRepo,omitempty"`

	LLMOSOperatorValues map[string]interface{}           `json:"llmosOperatorValues,omitempty"`
	PreInstructions     []applyinator.OneTimeInstruction `json:"preInstructions,omitempty"`
	PostInstructions    []applyinator.OneTimeInstruction `json:"postInstructions,omitempty"`
	Resources           []GenericMap                     `json:"manifest,omitempty"`

	RuntimeInstallerImage string `json:"runtimeInstallerImage,omitempty"`
	LLMOSInstallerImage   string `json:"llmosInstallerImage,omitempty"`
	// GlobalSystemImageRegistry specify the default registry used for LLMOS system images
	GlobalSystemImageRegistry string               `json:"globalSystemImageRegistry,omitempty"`
	Mirror                    string               `json:"mirror,omitempty"`
	Registries                *registries.Registry `json:"registries,omitempty"`
	ImageUtility              *image.Utility       `json:"imageUtility,omitempty"`
}

func Load

func Load(path string) (Config, error)

type GenericMap

type GenericMap struct {
	Data map[string]interface{} `json:"-"`
}

type Role

type Role string

type Runtime

type Runtime string

func GetRuntime

func GetRuntime(kubernetesVersion string) Runtime

type RuntimeConfig

type RuntimeConfig struct {
	Role            Role                   `json:"role,omitempty"`
	Server          string                 `json:"server,omitempty"`
	SANS            []string               `json:"tlsSans,omitempty"`
	NodeName        string                 `json:"nodeName,omitempty"`
	Address         string                 `json:"address,omitempty"`
	InternalAddress string                 `json:"internalAddress,omitempty"`
	Taints          []string               `json:"taints,omitempty"`
	Labels          []string               `json:"labels,omitempty"`
	Token           string                 `json:"token,omitempty"`
	ConfigValues    map[string]interface{} `json:"extraConfig,omitempty"`
	// SystemDefaultRegistry specify the mirror registry used for k8s runtime images
	SystemDefaultRegistry string `json:"systemDefaultRegistry,omitempty"`
}

RuntimeConfig contains the basic configuration for the k8s runtime

func (*RuntimeConfig) SetDefaults added in v0.2.0

func (cfg *RuntimeConfig) SetDefaults()

Jump to

Keyboard shortcuts

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