hybrid

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2025 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddKubeletRemediation added in v1.0.9

func AddKubeletRemediation(certPath string, err error) error

AddKubeletRemediation adds kubelet-specific remediation messages based on error type

func BuildKubeClient added in v1.0.5

func BuildKubeClient() (kubernetes.Interface, error)

BuildKubeClient builds a kubernetes client from the kubelet kubeconfig but with the iam-ra credentials file set if the node is running the iam-ra service, this will avoid starting a new session to make the kuberenetes api calls if the node is not running the iam-ra service, aws config will fallback to the default aws_config file, which either be a creds file created by ssm or if using iam-ra, will exec the aws_signing_helper

func IsDateValidationError added in v1.0.7

func IsDateValidationError(err error) bool

func IsNoCertError added in v1.0.7

func IsNoCertError(err error) bool

func LoadAWSConfigForRolesAnywhere

func LoadAWSConfigForRolesAnywhere(ctx context.Context, nodeConfig *api.NodeConfig) (aws.Config, error)

func NewHybridNodeProvider

func NewHybridNodeProvider(nodeConfig *api.NodeConfig, skipPhases []string, logger *zap.Logger, opts ...NodeProviderOpt) (nodeprovider.NodeProvider, error)

func PopulateNodeConfigDefaults

func PopulateNodeConfigDefaults(nodeConfig *api.NodeConfig)

func ValidateCertificate added in v1.0.9

func ValidateCertificate(certPath string, ca []byte) error

ValidateCertificate checks if there is an existing certificate and validates it against the provided CA

Types

type CertClockSkewError added in v1.0.9

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

func (*CertClockSkewError) Error added in v1.0.9

func (e *CertClockSkewError) Error() string

func (*CertClockSkewError) Unwrap added in v1.0.9

func (e *CertClockSkewError) Unwrap() error

type CertExpiredError added in v1.0.9

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

func (*CertExpiredError) Error added in v1.0.9

func (e *CertExpiredError) Error() string

func (*CertExpiredError) Unwrap added in v1.0.9

func (e *CertExpiredError) Unwrap() error

type CertFileError added in v1.0.9

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

func (*CertFileError) Error added in v1.0.9

func (e *CertFileError) Error() string

func (*CertFileError) Unwrap added in v1.0.9

func (e *CertFileError) Unwrap() error

type CertInvalidCAError added in v1.0.9

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

func (*CertInvalidCAError) Error added in v1.0.9

func (e *CertInvalidCAError) Error() string

func (*CertInvalidCAError) Unwrap added in v1.0.9

func (e *CertInvalidCAError) Unwrap() error

type CertInvalidFormatError added in v1.0.9

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

func (*CertInvalidFormatError) Error added in v1.0.9

func (e *CertInvalidFormatError) Error() string

func (*CertInvalidFormatError) Unwrap added in v1.0.9

func (e *CertInvalidFormatError) Unwrap() error

type CertNotFoundError added in v1.0.9

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

func (*CertNotFoundError) Error added in v1.0.9

func (e *CertNotFoundError) Error() string

func (*CertNotFoundError) Unwrap added in v1.0.9

func (e *CertNotFoundError) Unwrap() error

type CertParseCAError added in v1.0.9

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

func (*CertParseCAError) Error added in v1.0.9

func (e *CertParseCAError) Error() string

func (*CertParseCAError) Unwrap added in v1.0.9

func (e *CertParseCAError) Unwrap() error

type CertReadError added in v1.0.9

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

func (*CertReadError) Error added in v1.0.9

func (e *CertReadError) Error() string

func (*CertReadError) Unwrap added in v1.0.9

func (e *CertReadError) Unwrap() error

type HybridNodeProvider

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

func (*HybridNodeProvider) Cleanup

func (hnp *HybridNodeProvider) Cleanup() error

func (*HybridNodeProvider) ConfigureAws

func (hnp *HybridNodeProvider) ConfigureAws(ctx context.Context) error

func (*HybridNodeProvider) Enrich

func (*HybridNodeProvider) GetAspects

func (hnp *HybridNodeProvider) GetAspects() []system.SystemAspect

func (*HybridNodeProvider) GetConfig

func (hnp *HybridNodeProvider) GetConfig() *aws.Config

func (*HybridNodeProvider) GetDaemons

func (hnp *HybridNodeProvider) GetDaemons() ([]daemon.Daemon, error)

func (*HybridNodeProvider) GetNodeConfig

func (hnp *HybridNodeProvider) GetNodeConfig() *api.NodeConfig

func (*HybridNodeProvider) Logger

func (hnp *HybridNodeProvider) Logger() *zap.Logger

func (*HybridNodeProvider) PopulateNodeConfigDefaults

func (hnp *HybridNodeProvider) PopulateNodeConfigDefaults()

func (*HybridNodeProvider) PreProcessDaemon

func (hnp *HybridNodeProvider) PreProcessDaemon(ctx context.Context) error

func (*HybridNodeProvider) Validate added in v1.0.4

func (hnp *HybridNodeProvider) Validate() error

func (*HybridNodeProvider) ValidateConfig

func (hnp *HybridNodeProvider) ValidateConfig() error

func (*HybridNodeProvider) ValidateKubeletVersionSkew added in v1.0.9

func (hnp *HybridNodeProvider) ValidateKubeletVersionSkew() error

ValidateKubeletVersionSkew validates the version skew for kube-apiserver and kubelet.

func (*HybridNodeProvider) ValidateNodeIP added in v1.0.4

func (hnp *HybridNodeProvider) ValidateNodeIP() error

type Kubelet added in v1.0.9

type Kubelet interface {
	// Version returns the current kubelet version
	Version() (string, error)
}

Kubelet is the kubernetes node agent.

type Network added in v1.0.4

type Network interface {
	LookupIP(host string) ([]net.IP, error)
	ResolveBindAddress(bindAddress net.IP) (net.IP, error)
	InterfaceAddrs() ([]net.Addr, error)
}

Network interfaces with the host's network stack.

type NodeProviderOpt

type NodeProviderOpt func(*HybridNodeProvider)

func WithAWSConfig

func WithAWSConfig(config *aws.Config) NodeProviderOpt

func WithCertPath added in v1.0.7

func WithCertPath(path string) NodeProviderOpt

WithCertPath sets the path to the kubelet certificate

func WithCluster added in v1.0.4

func WithCluster(cluster *types.Cluster) NodeProviderOpt

WithCluster adds an EKS cluster to the HybridNodeProvider for testing purposes.

func WithKubelet added in v1.0.9

func WithKubelet(kubelet Kubelet) NodeProviderOpt

WithKubelet adds a kubelet struct to the HybridNodeProvider for testing purposes.

func WithNetwork added in v1.0.4

func WithNetwork(network Network) NodeProviderOpt

WithNetwork adds network util functions to the HybridNodeProvider for testing purposes.

type RolesAnywhereAWSConfigurator

type RolesAnywhereAWSConfigurator struct {
	Manager daemon.DaemonManager
	Logger  *zap.Logger
}

func (RolesAnywhereAWSConfigurator) Configure

func (c RolesAnywhereAWSConfigurator) Configure(ctx context.Context, nodeConfig *api.NodeConfig) error

type SSMAWSConfigurator

type SSMAWSConfigurator struct {
	Manager daemon.DaemonManager
	Logger  *zap.Logger
}

func (SSMAWSConfigurator) Configure

func (c SSMAWSConfigurator) Configure(ctx context.Context, nodeConfig *api.NodeConfig) error

Jump to

Keyboard shortcuts

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