Documentation ¶
Index ¶
- Constants
- func Sync(nodes []*Node, run func(i int, node *Node))
- type Facts
- type Node
- func (node *Node) Cmd(command string) error
- func (node *Node) CmdBytes(command string) (*bytes.Buffer, error)
- func (node *Node) CmdOutput(command string, output io.Writer) error
- func (node *Node) CmdPrefixStdout(command string) error
- func (node *Node) CmdStdout(command string) error
- func (node *Node) CmdString(command string) (string, error)
- func (node *Node) CmdWatcher(command string, watcher StreamWatcher) (err error)
- func (node *Node) Equal(local interface{}, remote string) bool
- func (node *Node) GatheringFacts() error
- func (node *Node) HideLog() *Node
- func (node *Node) HomeDir(join ...string) string
- func (node *Node) IsCentOS() bool
- func (node *Node) IsRoot() bool
- func (node *Node) IsUbuntu() bool
- func (node *Node) Logger(format string, params ...interface{})
- func (node *Node) Prefix() string
- func (node *Node) Pull(remotePath, localPath string) error
- func (node *Node) Retries(retries int) *Node
- func (node *Node) Scp(localPath, remotePath string) error
- func (node *Node) ScpContent(content []byte, remotePath string) error
- func (node *Node) Shell(shell string, watch StreamWatcher) error
- func (node *Node) Sudo() *Node
- func (node *Node) Vik8s(join ...string) string
- type Nodes
- type StreamWatcher
Constants ¶
View Source
const ( Sudo = 0b10 Log = 0b01 None = 0b00 )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Node ¶
type Node struct { Host string `ngx:"host" flag:"-"` Port int `ngx:"port" short:"p" help:"ssh port" def:"22"` User string `ngx:"user" short:"u" help:"ssh user" def:"root"` Password string `ngx:"password" short:"P" help:"ssh password"` PrivateKey string `ngx:"private-key" short:"i" help:"ssh private key" def:"$HOME/.ssh/id_rsa"` PrivateKeyRaw string `ngx:"private-key-raw" help:"ssh private key"` Passphrase string `ngx:"passphrase" flag:"passphrase" help:"private key passphrase"` Hostname string `ngx:"hostname" flag:"-"` Proxy string `ngx:"proxy"` ProxyNode *Node `ngx:"-" flag:"-"` Facts Facts `ngx:"-" flag:"-"` Timeout time.Duration `ngx:"-" flag:"-"` Ciphers []string `ngx:"-" flag:"-"` KeyExchanges []string `ngx:"-" flag:"-"` Fingerprint string `ngx:"-" flag:"-"` UseInsecureCipher bool `ngx:"-" flag:"-"` // contains filtered or unexported fields }
func (*Node) CmdPrefixStdout ¶ added in v0.5.0
func (*Node) CmdWatcher ¶ added in v0.5.0
func (node *Node) CmdWatcher(command string, watcher StreamWatcher) (err error)
func (*Node) GatheringFacts ¶ added in v0.5.0
type StreamWatcher ¶ added in v0.5.0
Click to show internal directories.
Click to hide internal directories.