Problem
When piping a command to openvdc console and said command fails, the error message reads: Failed to ssh to <ip address>. This would have you believe that the SSH connection failed while in reality that succeeded and it was the command afterwards that failed.
bash-4.2$ echo xxxx | openvdc console i-0000000017
/bin/bash: line 1: xxxx: command not found
FATA[0000] Failed ssh to 172.16.3.10:31195 error="Process exited with status 127"
Solution
Display different error messages for when the SSH connection failed and for when the command afterwards failed.
Problem
When piping a command to
openvdc consoleand said command fails, the error message reads:Failed to ssh to <ip address>.This would have you believe that the SSH connection failed while in reality that succeeded and it was the command afterwards that failed.Solution
Display different error messages for when the SSH connection failed and for when the command afterwards failed.