Documentation ¶
Overview ¶
mfi utility functions
Index ¶
Constants ¶
View Source
const SYSTEM_CFG = `` /* 4309-byte string literal not displayed */
View Source
const (
TEMPFILE_PREFIX = "mfi_deploy"
)
View Source
const WLAN_OVERWRITE = `
essid={{.WifiSSID}}
security=wpapsk
wpakey={{.WifiPassword}}
`
Variables ¶
View Source
var ErrWifiPasswordNotPresent = errors.New("Wifi password not present")
View Source
var ErrWifiSsidNotPresent = errors.New("Wifi SSID not present")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { EthernetConfig bool WlanOverwriteFilename string SystemCfgFilename string WifiSSID string WifiPassword string HwAddr string Host string }
func (*Config) FindDeviceOn ¶
func (*Config) RunStep1Wifi ¶
func (*Config) RunStep2PushConfig ¶
type SshCommands ¶
type SshCommands struct {
// contains filtered or unexported fields
}
func NewSshCommands ¶
func NewSshCommands() (s *SshCommands)
func (*SshCommands) Add ¶
func (s *SshCommands) Add(cmd string)
func (*SshCommands) AddFile ¶
func (s *SshCommands) AddFile(filename, text string)
func (*SshCommands) Exec ¶
func (s *SshCommands) Exec(host string) (err error)
Exec a command via ssh on the mfi switch. That's always on the mfi's own Wifi, so the IP is usually 192.168.2.20. Therefore its SSH Fingerprint always changes. We don't want SSH to complain about that: http://bit.ly/1Os4sx5
Click to show internal directories.
Click to hide internal directories.