Shell opens an interactive SSH shell session on the configured host. This method uses the local ssh command and inherits the current process's stdio streams, providing a fully interactive terminal experience. Returns an error if the SSH connection fails or if the client is nil.
()
| 86 | // |
| 87 | // Returns an error if the SSH connection fails or if the client is nil. |
| 88 | func (c *SSHClient) Shell() error { |
| 89 | if c == nil { |
| 90 | return fmt.Errorf("ssh client is nil") |
| 91 | } |
| 92 | |
| 93 | return ExecuteNodeShellWith(context.Background(), c.executor, c.User, c.Host, c.JumpHost) |
| 94 | } |
| 95 | |
| 96 | // ExecuteNodeShell opens an interactive SSH session to a Proxmox node. |
| 97 | // |