vmwareclouddirector

package
v2.24.12 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	ResourceNamePattern = "kubernetes-%s"
)

Variables

This section is empty.

Functions

func GetCredentialsForCluster

func GetCredentialsForCluster(cloud kubermaticv1.CloudSpec, secretKeySelector provider.SecretKeySelectorValueFunc) (creds *resources.VMwareCloudDirectorCredentials, err error)

GetCredentialsForCluster returns the credentials for the passed in cloud spec or an error.

func ListTemplates

func ListTemplates(ctx context.Context, auth Auth, catalogName string) (apiv1.VMwareCloudDirectorTemplateList, error)

func ValidateCredentials

func ValidateCredentials(ctx context.Context, dc *kubermaticv1.DatacenterSpecVMwareCloudDirector, username, password, apiToken, organization, vdc string) error

Types

type Auth

type Auth struct {
	Username      string
	Password      string
	APIToken      string
	Organization  string
	URL           string
	VDC           string
	AllowInsecure bool
}

type Client

type Client struct {
	Auth      *Auth
	VCDClient *govcd.VCDClient
}

func NewClientWithAuth

func NewClientWithAuth(auth Auth) (*Client, error)

func NewClientWithCreds

func NewClientWithCreds(username, password, apiToken, org, vdc, url string, allowInsecure bool) (*Client, error)

func (*Client) GetAuthenticatedClient

func (c *Client) GetAuthenticatedClient() (*govcd.VCDClient, error)

func (*Client) GetOrganization

func (c *Client) GetOrganization() (*govcd.Org, error)

func (*Client) GetVDCForOrg

func (c *Client) GetVDCForOrg(org govcd.Org) (*govcd.Vdc, error)

type Provider

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

func NewCloudProvider

func NewCloudProvider(dc *kubermaticv1.Datacenter, secretKeyGetter provider.SecretKeySelectorValueFunc) (*Provider, error)

NewCloudProvider creates a new VMware Cloud Director provider.

func (*Provider) CleanUpCloudProvider

func (p *Provider) CleanUpCloudProvider(ctx context.Context, cluster *kubermaticv1.Cluster, update provider.ClusterUpdater) (*kubermaticv1.Cluster, error)

func (*Provider) DefaultCloudSpec

func (p *Provider) DefaultCloudSpec(_ context.Context, _ *kubermaticv1.ClusterSpec) error

func (*Provider) InitializeCloudProvider

func (p *Provider) InitializeCloudProvider(ctx context.Context, cluster *kubermaticv1.Cluster, update provider.ClusterUpdater) (*kubermaticv1.Cluster, error)

func (*Provider) ReconcileCluster

func (p *Provider) ReconcileCluster(ctx context.Context, cluster *kubermaticv1.Cluster, update provider.ClusterUpdater) (*kubermaticv1.Cluster, error)

func (*Provider) ValidateCloudSpec

func (p *Provider) ValidateCloudSpec(_ context.Context, spec kubermaticv1.CloudSpec) error

func (*Provider) ValidateCloudSpecUpdate

func (p *Provider) ValidateCloudSpecUpdate(_ context.Context, oldSpec kubermaticv1.CloudSpec, newSpec kubermaticv1.CloudSpec) error

ValidateCloudSpecUpdate verifies whether an update of cloud spec is valid and permitted.

Jump to

Keyboard shortcuts

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