Documentation ¶
Index ¶
- Constants
- func GetTestDriverFlags() drivers.DriverOptionsMock
- func ValidateHostName(name string) bool
- func WaitForSSH(h *Host) error
- type Host
- func (h *Host) ConfigureAuth() error
- func (h *Host) CreateSSHClient() (ssh.Client, error)
- func (h *Host) CreateSSHShell() error
- func (h *Host) GetURL() (string, error)
- func (h *Host) IsActive() (bool, error)
- func (h *Host) Kill() error
- func (h *Host) PrintIP() error
- func (h *Host) Provision() error
- func (h *Host) Restart() error
- func (h *Host) RunSSHCommand(command string) (string, error)
- func (h *Host) Start() error
- func (h *Host) Stop() error
- func (h *Host) Upgrade() error
- type HostListItem
- type HostMetadata
- type HostMetadataV0
- type HostOptions
- type HostV0
Constants ¶
View Source
const (
HostTestName = "test-host"
)
Variables ¶
This section is empty.
Functions ¶
func GetTestDriverFlags ¶
func GetTestDriverFlags() drivers.DriverOptionsMock
Helper functions for tests meant to exported and used by other packages as well.
func ValidateHostName ¶
func WaitForSSH ¶
Types ¶
type Host ¶
type Host struct { ConfigVersion int Driver drivers.Driver DriverName string HostOptions *HostOptions Name string }
func GetDefaultTestHost ¶
func MigrateHostV0ToHostV1 ¶
validates host config and modifies if needed this is used for configuration updates
func (*Host) ConfigureAuth ¶
func (*Host) CreateSSHShell ¶
type HostListItem ¶
type HostListItem struct { Name string Active bool DriverName string State state.State URL string SwarmOptions swarm.SwarmOptions }
func GetHostListItems ¶
func GetHostListItems(hostList []*Host) []HostListItem
type HostMetadata ¶
type HostMetadata struct { ConfigVersion int DriverName string HostOptions HostOptions }
func MigrateHostMetadataV0ToHostMetadataV1 ¶
func MigrateHostMetadataV0ToHostMetadataV1(m *HostMetadataV0) *HostMetadata
fills nested host metadata and modifies if needed this is used for configuration updates
type HostMetadataV0 ¶
type HostOptions ¶
type HostOptions struct { Driver string Memory int Disk int EngineOptions *engine.EngineOptions SwarmOptions *swarm.SwarmOptions AuthOptions *auth.AuthOptions }
type HostV0 ¶
type HostV0 struct { Name string `json:"-"` Driver drivers.Driver DriverName string ConfigVersion int HostOptions *HostOptions StorePath string CaCertPath string CaPrivateKeyPath string ServerCertPath string ServerKeyPath string ClientCertPath string SwarmHost string SwarmMaster bool SwarmDiscovery string ClientKeyPath string }
Click to show internal directories.
Click to hide internal directories.