Documentation
¶
Index ¶
- func CloudConfigToString(c *CloudConfig) (string, error)
- func GetNetworkSpecs(ctx context.Context, session *Session, devices object.VirtualDeviceList, ...) ([]types.BaseVirtualDeviceConfigSpec, error)
- func New(configVarResolver *providerconfig.ConfigVarResolver) cloudprovidertypes.Provider
- type CloudConfig
- type Config
- type DiskOpts
- type GlobalOpts
- type RawConfig
- type Server
- type Session
- type VirtualCenterConfig
- type WorkspaceOpts
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CloudConfigToString ¶ added in v0.8.0
func CloudConfigToString(c *CloudConfig) (string, error)
func GetNetworkSpecs ¶ added in v1.5.2
func GetNetworkSpecs(ctx context.Context, session *Session, devices object.VirtualDeviceList, network string) ([]types.BaseVirtualDeviceConfigSpec, error)
func New ¶
func New(configVarResolver *providerconfig.ConfigVarResolver) cloudprovidertypes.Provider
New returns a VSphere provider
Types ¶
type CloudConfig ¶ added in v0.8.0
type CloudConfig struct {
Global GlobalOpts
Disk DiskOpts
Workspace WorkspaceOpts
VirtualCenter map[string]*VirtualCenterConfig
}
CloudConfig is used to read and store information from the cloud configuration file
type DiskOpts ¶ added in v0.8.0
type DiskOpts struct {
SCSIControllerType string `dcfg:"scsicontrollertype"`
}
type GlobalOpts ¶ added in v0.8.0
type GlobalOpts struct {
User string `gcfg:"user"`
Password string `gcfg:"password"`
InsecureFlag bool `gcfg:"insecure-flag"`
VCenterPort string `gcfg:"port"`
WorkingDir string `gcfg:"working-dir"`
Datacenter string `gcfg:"datacenter"`
DefaultDatastore string `gcfg:"datastore"`
VCenterIP string `gcfg:"server"`
}
type RawConfig ¶
type RawConfig struct {
TemplateVMName providerconfig.ConfigVarString `json:"templateVMName"`
VMNetName providerconfig.ConfigVarString `json:"vmNetName,omitempty"`
Username providerconfig.ConfigVarString `json:"username,omitempty"`
Password providerconfig.ConfigVarString `json:"password,omitempty"`
VSphereURL providerconfig.ConfigVarString `json:"vsphereURL,omitempty"`
Datacenter providerconfig.ConfigVarString `json:"datacenter"`
Cluster providerconfig.ConfigVarString `json:"cluster"`
Folder providerconfig.ConfigVarString `json:"folder,omitempty"`
Datastore providerconfig.ConfigVarString `json:"datastore"`
CPUs int32 `json:"cpus"`
MemoryMB int64 `json:"memoryMB"`
DiskSizeGB *int64 `json:"diskSizeGB,omitempty"`
AllowInsecure providerconfig.ConfigVarBool `json:"allowInsecure"`
}
type Session ¶ added in v1.5.2
func NewSession ¶ added in v1.5.2
NewSession creates a vCenter client with initialized finder
type VirtualCenterConfig ¶ added in v0.8.0
Click to show internal directories.
Click to hide internal directories.