Documentation ¶
Overview ¶
todo we should move this to oses as platform specific
Index ¶
- type Client
- func (s *Client) Close()
- func (s *Client) CombinedOutput(cmds ...string) ([]byte, error)
- func (s *Client) CombinedRead() ([]byte, error)
- func (s *Client) Connect() (*ssh.Session, error)
- func (s *Client) Exec(commands ...string) error
- func (s *Client) Output(cmds ...string) ([]byte, error)
- func (s *Client) OutputPtrs(ptrs []*string) error
- func (c *Client) PossibleRebootWait()
- func (s *Client) RawClient() (*ssh.Client, error)
- func (s *Client) ReadStderr() ([]byte, error)
- func (s *Client) ReadStdout() ([]byte, error)
- func (s *Client) RemoteInfo() (*RemoteInfo, error)
- func (s *Client) Run(cmds ...string) error
- func (s *Client) Shell() error
- type ClientOptions
- type RemoteInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Options *ClientOptions Session *ssh.Session // contains filtered or unexported fields }
func (*Client) CombinedRead ¶
func (*Client) OutputPtrs ¶
func (*Client) PossibleRebootWait ¶
func (c *Client) PossibleRebootWait()
func (*Client) ReadStderr ¶
func (*Client) ReadStdout ¶
func (*Client) RemoteInfo ¶
func (s *Client) RemoteInfo() (*RemoteInfo, error)
type ClientOptions ¶
type RemoteInfo ¶
type RemoteInfo struct { OS string `json:"os" yaml:"os"` Hostname string `json:"hostname" yaml:"hostname"` KernelVersion string `json:"kernel_version" yaml:"kernel_version"` KernelRelease string `json:"kernel_release" yaml:"kernel_release"` Architecture string `json:"arch" yaml:"arch"` HetznerRescueMode string `json:"hetzner_rescue_mode" yaml:"hetzner_rescue_mode"` }
Click to show internal directories.
Click to hide internal directories.