Ssh Command¶
Often the ssh command needs to be used to login to remote machines. As the interaction with such machines could be frequent via the ssh command, it is often a good idea to include them into the ~/.ssh/config file. To simplify interaction, we provide a simple ssh command in cloudmesh.
The manual page of the ssh command can be found at: ssh
Lists¶
To lists the hostsnames that are present in the ~/.ssh/config file use the command
ssh list
To list the contents of the ~/.ssh/config file use the command
ssh cat
Tos showcase a nice table you can use either of the commands
ssh table ssh list --format=table
Executing Commands¶
To execute a command on a remote host you simply can use the ssh command eithe rin the shell or in cloudmesh client.
ssh ARGUMENTS
executes the ssh command with the given arguments
Example:
ssh myhost
conducts an ssh login to myhost if it is defined in ~/.ssh/config file