Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type VSphereConnection ¶
type VSphereConnection struct { Client *govmomi.Client RestClient *rest.Client Username string Password string Hostname string Port string Insecure bool Config *vsphere.VSphereConfig }
VSphereConnection contains information for connecting to vCenter
func NewVSphereConnection ¶
func NewVSphereConnection(username, password string, cfg *vsphere.VSphereConfig) *VSphereConnection
func (*VSphereConnection) Connect ¶
func (connection *VSphereConnection) Connect(ctx context.Context) error
Connect makes connection to vCenter and sets VSphereConnection.Client. If connection.Client is already set, it obtains the existing user session. if user session is not valid, connection.Client will be set to the new client.
Click to show internal directories.
Click to hide internal directories.