vsphere

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2018 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProviderPrefix string = "vsphere://"

	//CredentialManagerErrMsg = "The Credential Manager is not initialized"
	NodeNotFoundErrMsg = "Node not found"
)
View Source
const (
	FindVMByUUID FindVM = iota // 0
	FindVMByName               // 1

	// Error Messages
	VCenterNotFoundErrMsg    = "vCenter not found"
	DatacenterNotFoundErrMsg = "Datacenter not found"
	VMNotFoundErrMsg         = "VM not found"
)
View Source
const (
	ProviderName string = "vsphere"
)

Variables

View Source
var (
	ErrVCenterNotFound    = errors.New(VCenterNotFoundErrMsg)
	ErrDatacenterNotFound = errors.New(DatacenterNotFoundErrMsg)
	ErrVMNotFound         = errors.New(VMNotFoundErrMsg)
)

Error constants

View Source
var (
	//ErrCredentialManager = errors.New(CredentialManagerErrMsg)
	ErrNodeNotFound = errors.New(NodeNotFoundErrMsg)
)

Error constants

Functions

This section is empty.

Types

type DatacenterInfo

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

type FindVM

type FindVM int

func (FindVM) String

func (f FindVM) String() string

type GRPCServer

type GRPCServer interface {
	Start()
}

GRPCServer interface

type NodeInfo

type NodeInfo struct {
	UUID          string
	NodeName      string
	NodeAddresses []v1.NodeAddress
	// contains filtered or unexported fields
}

Stores info about the kubernetes node

type NodeManager

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

func (*NodeManager) AddNodeInfoToVCList

func (nm *NodeManager) AddNodeInfoToVCList(vcenter string, datacenter string, node *NodeInfo)

AddNodeInfoToVCList creates a relational mapping from VC -> DC -> VM/Node

func (*NodeManager) DiscoverNode

func (nm *NodeManager) DiscoverNode(nodeID string, searchBy FindVM) error

func (*NodeManager) ExportNodes

func (nm *NodeManager) ExportNodes(vcenter string, datacenter string, nodeList *[]*pb.Node) error

ExportNodes transforms the NodeInfoList to []*pb.Node

func (*NodeManager) FindDatacenterInfoInVCList

func (nm *NodeManager) FindDatacenterInfoInVCList(vcenter string, datacenter string) (*DatacenterInfo, error)

FindDatacenterInfoInVCList retrieves the DatacenterInfo from the tree

func (*NodeManager) FindNodeInfoInVCList

func (nm *NodeManager) FindNodeInfoInVCList(vcenter string, datacenter string, UUID string) (*NodeInfo, error)

FindNodeInfoInVCList retrieves the NodeInfo from the tree

func (*NodeManager) RegisterNode

func (nm *NodeManager) RegisterNode(node *v1.Node)

RegisterNode - Handler when node is removed from k8s cluster.

func (*NodeManager) UnregisterNode

func (nm *NodeManager) UnregisterNode(node *v1.Node)

UnregisterNode - Handler when node is removed from k8s cluster.

type VCenterInfo

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

type VSphere

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

VSphere is an implementation of cloud provider Interface for VSphere.

func (*VSphere) Clusters

func (vs *VSphere) Clusters() (cloudprovider.Clusters, bool)

func (*VSphere) HasClusterID

func (vs *VSphere) HasClusterID() bool

func (*VSphere) Initialize

func (vs *VSphere) Initialize(clientBuilder controller.ControllerClientBuilder)

func (*VSphere) Instances

func (vs *VSphere) Instances() (cloudprovider.Instances, bool)

func (*VSphere) LoadBalancer

func (vs *VSphere) LoadBalancer() (cloudprovider.LoadBalancer, bool)

func (*VSphere) ProviderName

func (vs *VSphere) ProviderName() string

func (*VSphere) Routes

func (vs *VSphere) Routes() (cloudprovider.Routes, bool)

func (*VSphere) ScrubDNS

func (vs *VSphere) ScrubDNS(nameservers, searches []string) (nsOut, srchOut []string)

func (*VSphere) Zones

func (vs *VSphere) Zones() (cloudprovider.Zones, bool)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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