Vm Ssh

SSH to a VM

Synopsis

SSH to a VM. Carbon will call exec on the ssh binary. This means the SSH process takes over the carbon process. So SSH agents should just work.

carbon vm ssh [flags]

Examples

# SSH to a VM
carbon vm ssh -n vm-name
# execute one off command on a VM
carbon vm ssh -n vm-name -- cat /etc/passwd
# proxy through a bastion
carbon vm ssh -n vm-name -- -oProxyCommand="carbon vm ssh -n bastion -- -W %h:%p"
# forward ssh agent
carbon vm ssh -n vm-name -- -A
# open socks proxy
carbon vm ssh -n vm-name -- -D 1080

Options

  -h, --help   help for ssh

Options inherited from parent commands

      --config string   config file (default is $HOME/.carbon.yaml)
      --debug           Debug mode
      --host strings    Hostname or IP Address.
  -i, --id string       ID of machine to start.
  -j, --json            Output in JSON
  -n, --name string     Name of the VM.
  -u, --user string     SSH Username. (default "ubuntu")

SEE ALSO

Auto generated by spf13/cobra on 10-Oct-2024
Last modified October 29, 2024: update (0deef86)