Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncodePowershellCommand ¶
Types ¶
type Factory ¶
type Factory struct {
}
func (*Factory) New ¶
func (f *Factory) New(config config.SourceConfig, vCenterManager commandparser.VCenterManager, messenger messenger.Messenger) (commandparser.VmConstruct, error)
type GuestManager ¶
type IaasClient ¶
type IaasClient interface {
UploadArtifact(vmInventoryPath, artifact, destination, username, password string) error
MakeDirectory(vmInventoryPath, path, username, password string) error
Start(vmInventoryPath, username, password, command string, args ...string) (string, error)
WaitForExit(vmInventoryPath, username, password, pid string) (int, error)
IsPoweredOff(vmInventoryPath string) (bool, error)
}
type RebootWaiterI ¶
type RebootWaiterI interface {
WaitForRebootFinished() error
}
type ScriptExecutor ¶
type ScriptExecutor struct {
// contains filtered or unexported fields
}
func NewScriptExecutor ¶
func NewScriptExecutor(remoteManager remotemanager.RemoteManager) *ScriptExecutor
func (*ScriptExecutor) ExecutePostRebootScript ¶
func (e *ScriptExecutor) ExecutePostRebootScript(timeout time.Duration) error
func (*ScriptExecutor) ExecuteSetupScript ¶
func (e *ScriptExecutor) ExecuteSetupScript(stembuildVersion string, setupFlags []string) error
type ScriptExecutorI ¶
type VMConnectionValidator ¶
type VMConnectionValidator interface {
Validate() error
}
type VMConstruct ¶
type VMConstruct struct {
Client IaasClient
RebootWaitTime time.Duration
SetupFlags []string
// contains filtered or unexported fields
}
func NewVMConstruct ¶
func NewVMConstruct( ctx context.Context, remoteManager remotemanager.RemoteManager, vmUsername, vmPassword, vmInventoryPath string, client IaasClient, guestManager GuestManager, winRMEnabler WinRMEnabler, vmConnectionValidator VMConnectionValidator, messenger messenger.Messenger, poller poller.PollerI, versionGetter VersionGetter, rebootWaiter RebootWaiterI, scriptExecutor ScriptExecutorI, setupFlags []string, ) *VMConstruct
func (*VMConstruct) PrepareVM ¶
func (c *VMConstruct) PrepareVM() error
type VersionGetter ¶
type VersionGetter interface {
GetVersion() string
}
type WinRMConnectionValidator ¶
type WinRMConnectionValidator struct {
RemoteManager remotemanager.RemoteManager
}
func (*WinRMConnectionValidator) Validate ¶
func (v *WinRMConnectionValidator) Validate() error
type WinRMEnabler ¶
type WinRMEnabler interface {
Enable() error
}
type WinRMManager ¶
type WinRMManager struct {
GuestManager GuestManager
Unarchiver zipUnarchiver
}
func (*WinRMManager) Enable ¶
func (w *WinRMManager) Enable() error
Source Files
¶
Click to show internal directories.
Click to hide internal directories.