cluster

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2024 License: MPL-2.0 Imports: 9 Imported by: 3

Documentation

Index

Constants

View Source
const AffiliateType = resource.Type("Affiliates.cluster.talos.dev")

AffiliateType is type of Affiliate resource.

View Source
const ConfigID = resource.ID("cluster")

ConfigID the singleton config resource ID.

View Source
const ConfigType = resource.Type("DiscoveryConfigs.cluster.talos.dev")

ConfigType is type of Config resource.

View Source
const IdentityType = resource.Type("Identities.cluster.talos.dev")

IdentityType is type of Identity resource.

View Source
const InfoID = resource.ID("current")

InfoID is the resource ID for the current cluster info.

View Source
const InfoType = resource.Type("Infos.cluster.talos.dev")

InfoType is type of Info resource.

View Source
const LocalIdentity = resource.ID("local")

LocalIdentity is the resource ID for the local node identity.

View Source
const MemberType = resource.Type("Members.cluster.talos.dev")

MemberType is type of Member resource.

View Source
const NamespaceName resource.Namespace = "cluster"

NamespaceName contains resources related to cluster as a whole.

View Source
const RawNamespaceName resource.Namespace = "cluster-raw"

RawNamespaceName contains raw resources which haven't gone through the merge phase yet.

Variables

This section is empty.

Functions

This section is empty.

Types

type Affiliate

Affiliate resource holds information about cluster affiliate: it is discovered potential cluster member and/or KubeSpan peer.

Controller builds local Affiliate structure for the node itself, other Affiliates are pulled from the registry during the discovery process.

func NewAffiliate

func NewAffiliate(namespace resource.Namespace, id resource.ID) *Affiliate

NewAffiliate initializes the Affiliate resource.

type AffiliateExtension added in v1.4.0

type AffiliateExtension struct{}

AffiliateExtension provides auxiliary methods for Affiliate.

func (AffiliateExtension) ResourceDefinition added in v1.4.0

func (r AffiliateExtension) ResourceDefinition() meta.ResourceDefinitionSpec

ResourceDefinition implements typed.Extension interface.

type AffiliateSpec

type AffiliateSpec struct {
	NodeID          string                `yaml:"nodeId" protobuf:"1"`
	Addresses       []netip.Addr          `yaml:"addresses" protobuf:"2"`
	Hostname        string                `yaml:"hostname" protobuf:"3"`
	Nodename        string                `yaml:"nodename,omitempty" protobuf:"4"`
	OperatingSystem string                `yaml:"operatingSystem" protobuf:"5"`
	MachineType     machine.Type          `yaml:"machineType" protobuf:"6"`
	KubeSpan        KubeSpanAffiliateSpec `yaml:"kubespan,omitempty" protobuf:"7"`
	ControlPlane    *ControlPlane         `yaml:"controlPlane,omitempty" protobuf:"8"`
}

AffiliateSpec describes Affiliate state.

func (AffiliateSpec) DeepCopy

func (o AffiliateSpec) DeepCopy() AffiliateSpec

DeepCopy generates a deep copy of AffiliateSpec.

func (*AffiliateSpec) Merge

func (spec *AffiliateSpec) Merge(other *AffiliateSpec)

Merge two AffiliateSpecs.

type Config

Config resource holds KubeSpan configuration.

func NewConfig

func NewConfig(namespace resource.Namespace, id resource.ID) *Config

NewConfig initializes a Config resource.

type ConfigExtension added in v1.4.0

type ConfigExtension struct{}

ConfigExtension provides auxiliary methods for Config.

func (ConfigExtension) ResourceDefinition added in v1.4.0

func (ConfigExtension) ResourceDefinition() meta.ResourceDefinitionSpec

ResourceDefinition implements typed.Extension interface.

type ConfigSpec

type ConfigSpec struct {
	DiscoveryEnabled          bool   `yaml:"discoveryEnabled" protobuf:"1"`
	RegistryKubernetesEnabled bool   `yaml:"registryKubernetesEnabled" protobuf:"2"`
	RegistryServiceEnabled    bool   `yaml:"registryServiceEnabled" protobuf:"3"`
	ServiceEndpoint           string `yaml:"serviceEndpoint" protobuf:"4"`
	ServiceEndpointInsecure   bool   `yaml:"serviceEndpointInsecure,omitempty" protobuf:"5"`
	ServiceEncryptionKey      []byte `yaml:"serviceEncryptionKey" protobuf:"6"`
	ServiceClusterID          string `yaml:"serviceClusterID" protobuf:"7"`
}

ConfigSpec describes KubeSpan configuration.

func (ConfigSpec) DeepCopy

func (o ConfigSpec) DeepCopy() ConfigSpec

DeepCopy generates a deep copy of ConfigSpec.

type ControlPlane added in v1.5.0

type ControlPlane struct {
	APIServerPort int `yaml:"port" protobuf:"1"`
}

ControlPlane describes ControlPlane data if any.

type Identity

Identity resource holds node identity (as a member of the cluster).

func NewIdentity

func NewIdentity(namespace resource.Namespace, id resource.ID) *Identity

NewIdentity initializes a Identity resource.

type IdentityExtension added in v1.4.0

type IdentityExtension struct{}

IdentityExtension provides auxiliary methods for Identity.

func (IdentityExtension) ResourceDefinition added in v1.4.0

func (IdentityExtension) ResourceDefinition() meta.ResourceDefinitionSpec

ResourceDefinition implements typed.Extension interface.

type IdentitySpec

type IdentitySpec struct {
	// NodeID is a random value which is persisted across reboots,
	// but it gets reset on wipe.
	NodeID string `yaml:"nodeId" protobuf:"1"`
}

IdentitySpec describes status of rendered secrets.

Note: IdentitySpec is persisted on disk in the STATE partition, so YAML serialization should be kept backwards compatible.

func (IdentitySpec) DeepCopy

func (o IdentitySpec) DeepCopy() IdentitySpec

DeepCopy generates a deep copy of IdentitySpec.

type Info added in v1.4.0

Info resource holds cluster information.

func NewInfo added in v1.4.0

func NewInfo() *Info

NewInfo initializes an Info resource.

type InfoExtension added in v1.4.0

type InfoExtension struct{}

InfoExtension provides auxiliary methods for Info.

func (InfoExtension) ResourceDefinition added in v1.4.0

func (InfoExtension) ResourceDefinition() meta.ResourceDefinitionSpec

ResourceDefinition implements typed.Extension interface.

type InfoSpec added in v1.4.0

type InfoSpec struct {
	ClusterID   string `yaml:"clusterId" protobuf:"1"`
	ClusterName string `yaml:"clusterName" protobuf:"2"`
}

InfoSpec describes cluster information.

func (InfoSpec) DeepCopy added in v1.4.0

func (o InfoSpec) DeepCopy() InfoSpec

DeepCopy generates a deep copy of InfoSpec.

type KubeSpanAffiliateSpec

type KubeSpanAffiliateSpec struct {
	PublicKey           string           `yaml:"publicKey" protobuf:"1"`
	Address             netip.Addr       `yaml:"address" protobuf:"2"`
	AdditionalAddresses []netip.Prefix   `yaml:"additionalAddresses" protobuf:"3"`
	Endpoints           []netip.AddrPort `yaml:"endpoints" protobuf:"4"`
}

KubeSpanAffiliateSpec describes additional information specific for the KubeSpan.

type Member

Member resource contains information about discovered cluster members.

Members are usually derived from Affiliates.

func NewMember

func NewMember(namespace resource.Namespace, id resource.ID) *Member

NewMember initializes a Member resource.

type MemberExtension added in v1.4.0

type MemberExtension struct{}

MemberExtension provides auxiliary methods for Member.

func (MemberExtension) ResourceDefinition added in v1.4.0

func (MemberExtension) ResourceDefinition() meta.ResourceDefinitionSpec

ResourceDefinition implements typed.Extension interface.

type MemberSpec

type MemberSpec struct {
	NodeID          string        `yaml:"nodeId" protobuf:"1"`
	Addresses       []netip.Addr  `yaml:"addresses" protobuf:"2"`
	Hostname        string        `yaml:"hostname" protobuf:"3"`
	MachineType     machine.Type  `yaml:"machineType" protobuf:"4"`
	OperatingSystem string        `yaml:"operatingSystem" protobuf:"5"`
	ControlPlane    *ControlPlane `yaml:"controlPlane,omitempty" protobuf:"6"`
}

MemberSpec describes Member state.

func (MemberSpec) DeepCopy

func (o MemberSpec) DeepCopy() MemberSpec

DeepCopy generates a deep copy of MemberSpec.

Jump to

Keyboard shortcuts

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