Documentation ¶
Index ¶
- func Chmod(factory SshConfigFactory, remotePath string, mode os.FileMode) error
- func CopyFile(srcPath, dstPath string) (int64, error)
- func CopyTree(srcPath, dstPath string) error
- func DeleteRemoteFiles(factory SshConfigFactory, paths ...string) error
- func Export(path string, m *model.Model) error
- func KillService(factory SshConfigFactory, name string) error
- func LaunchService(factory SshConfigFactory, name, cfg string, sudo bool) error
- func RemoteConsole(factory SshConfigFactory, cmd string) error
- func RemoteExec(sshConfig SshConfigFactory, cmd string) (string, error)
- func RemoteExecAll(sshConfig SshConfigFactory, cmds ...string) (string, error)
- func RemoteExecAllTo(sshConfig SshConfigFactory, out io.Writer, cmds ...string) error
- func RemoteFileList(factory SshConfigFactory, path string) ([]os.FileInfo, error)
- func RemoteKill(factory SshConfigFactory, match string) error
- func RemoteKillFilter(factory SshConfigFactory, match string, anti string) error
- func RemoteShell(factory SshConfigFactory) error
- func RenderTemplate(src, dst string, m *model.Model, data interface{}) error
- func RenderTemplateFS(srcFS fs.FS, src string, dst string, m *model.Model, data interface{}) error
- func RetrieveRemoteFiles(factory SshConfigFactory, localPath string, paths ...string) error
- func SendData(factory SshConfigFactory, data []byte, remotePath string) error
- func SendFile(factory SshConfigFactory, localPath string, remotePath string) error
- func StdoutTail(data []byte)
- func SummarizeIperf(data []byte) (*model.IperfSummary, error)
- func SummarizeIperfUdp(data []byte) (*model.IperfUdpSummary, error)
- func SummarizeSar(data []byte) (*model.HostSummary, error)
- func TemplateFuncMap(m *model.Model) template.FuncMap
- type Process
- type SshConfigFactory
- type SshConfigFactoryImpl
- func (factory *SshConfigFactoryImpl) Address() string
- func (factory *SshConfigFactoryImpl) Config() *ssh.ClientConfig
- func (factory *SshConfigFactoryImpl) Hostname() string
- func (factory *SshConfigFactoryImpl) KeyPath() string
- func (factory *SshConfigFactoryImpl) Port() int
- func (factory *SshConfigFactoryImpl) User() string
- type TailFunction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Chmod ¶ added in v0.4.1
func Chmod(factory SshConfigFactory, remotePath string, mode os.FileMode) error
func DeleteRemoteFiles ¶
func DeleteRemoteFiles(factory SshConfigFactory, paths ...string) error
func KillService ¶
func KillService(factory SshConfigFactory, name string) error
func LaunchService ¶
func LaunchService(factory SshConfigFactory, name, cfg string, sudo bool) error
func RemoteConsole ¶
func RemoteConsole(factory SshConfigFactory, cmd string) error
func RemoteExec ¶
func RemoteExec(sshConfig SshConfigFactory, cmd string) (string, error)
func RemoteExecAll ¶
func RemoteExecAll(sshConfig SshConfigFactory, cmds ...string) (string, error)
func RemoteExecAllTo ¶
func RemoteExecAllTo(sshConfig SshConfigFactory, out io.Writer, cmds ...string) error
func RemoteFileList ¶
func RemoteFileList(factory SshConfigFactory, path string) ([]os.FileInfo, error)
func RemoteKill ¶
func RemoteKill(factory SshConfigFactory, match string) error
func RemoteKillFilter ¶
func RemoteKillFilter(factory SshConfigFactory, match string, anti string) error
func RemoteShell ¶
func RemoteShell(factory SshConfigFactory) error
func RenderTemplateFS ¶
func RetrieveRemoteFiles ¶
func RetrieveRemoteFiles(factory SshConfigFactory, localPath string, paths ...string) error
func SendData ¶ added in v0.4.1
func SendData(factory SshConfigFactory, data []byte, remotePath string) error
func StdoutTail ¶
func StdoutTail(data []byte)
func SummarizeIperf ¶
func SummarizeIperf(data []byte) (*model.IperfSummary, error)
func SummarizeIperfUdp ¶
func SummarizeIperfUdp(data []byte) (*model.IperfUdpSummary, error)
func SummarizeSar ¶
func SummarizeSar(data []byte) (*model.HostSummary, error)
Types ¶
type Process ¶
func NewProcess ¶
func (*Process) WithTail ¶
func (prc *Process) WithTail(tail TailFunction) *Process
type SshConfigFactory ¶
type SshConfigFactoryImpl ¶
type SshConfigFactoryImpl struct {
// contains filtered or unexported fields
}
func NewSshConfigFactory ¶
func NewSshConfigFactory(h *model.Host) *SshConfigFactoryImpl
func (*SshConfigFactoryImpl) Address ¶
func (factory *SshConfigFactoryImpl) Address() string
func (*SshConfigFactoryImpl) Config ¶
func (factory *SshConfigFactoryImpl) Config() *ssh.ClientConfig
func (*SshConfigFactoryImpl) Hostname ¶
func (factory *SshConfigFactoryImpl) Hostname() string
func (*SshConfigFactoryImpl) KeyPath ¶
func (factory *SshConfigFactoryImpl) KeyPath() string
func (*SshConfigFactoryImpl) Port ¶
func (factory *SshConfigFactoryImpl) Port() int
func (*SshConfigFactoryImpl) User ¶
func (factory *SshConfigFactoryImpl) User() string
type TailFunction ¶
type TailFunction func(data []byte)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.