Documentation ¶
Overview ¶
Package kubernetes provides functionality to bootstrap a Kubernetes cluster, or join an exiting one.
Index ¶
- type KubeWrapper
- func (k *KubeWrapper) InitCluster(ctx context.Context, cloudServiceAccountURI, versionString, clusterName string, ...) ([]byte, error)
- func (k *KubeWrapper) JoinCluster(ctx context.Context, args *kubeadm.BootstrapTokenDiscovery, peerRole role.Role, ...) error
- func (k *KubeWrapper) StartKubelet(log *logger.Logger) error
- type ProviderMetadata
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type KubeWrapper ¶
type KubeWrapper struct {
// contains filtered or unexported fields
}
KubeWrapper implements Cluster interface.
func New ¶
func New(cloudProvider string, clusterUtil clusterUtil, configProvider configurationProvider, client k8sapi.Client, providerMetadata ProviderMetadata, helmClient helmClient, kubeAPIWaiter kubeAPIWaiter, ) *KubeWrapper
New creates a new KubeWrapper with real values.
func (*KubeWrapper) InitCluster ¶
func (k *KubeWrapper) InitCluster( ctx context.Context, cloudServiceAccountURI, versionString, clusterName string, measurementSalt []byte, helmReleasesRaw []byte, conformanceMode bool, kubernetesComponents components.Components, log *logger.Logger, ) ([]byte, error)
InitCluster initializes a new Kubernetes cluster and applies pod network provider.
func (*KubeWrapper) JoinCluster ¶
func (k *KubeWrapper) JoinCluster(ctx context.Context, args *kubeadm.BootstrapTokenDiscovery, peerRole role.Role, k8sComponents components.Components, log *logger.Logger) error
JoinCluster joins existing Kubernetes cluster.
func (*KubeWrapper) StartKubelet ¶
func (k *KubeWrapper) StartKubelet(log *logger.Logger) error
StartKubelet starts the kubelet service.
type ProviderMetadata ¶
type ProviderMetadata interface { // UID returns the unique identifier for the constellation. UID(ctx context.Context) (string, error) // Self retrieves the current instance. Self(ctx context.Context) (metadata.InstanceMetadata, error) // GetLoadBalancerEndpoint retrieves the load balancer endpoint. GetLoadBalancerEndpoint(ctx context.Context) (string, error) }
ProviderMetadata implementers read/write cloud provider metadata.
Directories ¶
Path | Synopsis |
---|---|
Package k8sapi is used to interact with the Kubernetes API to create or update required resources.
|
Package k8sapi is used to interact with the Kubernetes API to create or update required resources. |
resources
Package resources contains Kubernetes configs and policies for Constellation.
|
Package resources contains Kubernetes configs and policies for Constellation. |
Package kubewaiter is used to wait for the Kubernetes API to be available.
|
Package kubewaiter is used to wait for the Kubernetes API to be available. |
Click to show internal directories.
Click to hide internal directories.