clustermeta

package
v0.2.12 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PKE       = "PKE"
	EKS       = "EKS"
	GKE       = "GKE"
	AKS       = "AKS"
	KINDD     = "KIND"
	IKS       = "IKS"
	OPENSHIFT = "OPENSHIFT"
)
View Source
const (
	AMAZON  = "amazon"
	AZURE   = "azure"
	GOOGLE  = "google"
	VSPHERE = "vsphere"
	KINDP   = "kind"
	CISCO   = "cisco"
)

Variables

This section is empty.

Functions

func DetectDistribution

func DetectDistribution(ctx context.Context, client client.Client, node *corev1.Node) (string, error)

func DetectProvider

func DetectProvider(ctx context.Context, client client.Client, node *corev1.Node) (string, error)

func GetClusterMetadata

func GetClusterMetadata(ctx context.Context, client client.Client) (v1alpha1.ClusterMetadata, error)

func IsAKS

func IsAKS(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsAmazon

func IsAmazon(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

func IsAzure

func IsAzure(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

func IsCisco

func IsCisco(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

func IsEKS

func IsEKS(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsGKE

func IsGKE(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsGoogle

func IsGoogle(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

func IsIKS

func IsIKS(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsKIND

func IsKIND(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsKind

func IsKind(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

func IsOpenShift added in v0.2.9

func IsOpenShift(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsPKE

func IsPKE(ctx context.Context, client client.Client, node *corev1.Node) (match bool, distribution string, err error)

func IsUnknownDistributionError

func IsUnknownDistributionError(err error) bool

func IsUnknownProviderError

func IsUnknownProviderError(err error) bool

func IsVsphere

func IsVsphere(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

Types

type IsDistribution

type IsDistribution func(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

type IsProvider

type IsProvider func(ctx context.Context, client client.Client, node *corev1.Node) (bool, string, error)

type UnknownDistributionError

type UnknownDistributionError struct{}

func (UnknownDistributionError) Error

type UnknownProviderError

type UnknownProviderError struct{}

func (UnknownProviderError) Error

func (UnknownProviderError) Error() string

Jump to

Keyboard shortcuts

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