platform9 / ssh-provider

SSH Machine Controller for the Cluster API
11 stars 4 forks source link

Remove logging from ssh machine client #35

Closed dlipovetsky closed 6 years ago

dlipovetsky commented 6 years ago

Introduced by https://github.com/platform9/ssh-provider/pull/27

The log calls are writing bytes:

2018/07/31 18:51:20 Not able to verify machine SSH identity: No public keys given. Continuing...
2018/07/31 18:51:20 []
2018/07/31 18:51:20 [99 104 109 111 100 58 32 105 110 118 97 108 105 100 32 109 111 100 101 58 32 39 52 57 51 39 10 84 114 121 32 39 99 104 109 111 100 32 45 45 104 101 108 112 39 32 102 111 114 32 109 111 114 101 32 105 110 102 111 114 109 97 116 105 111 110 46 10]
2018/07/31 18:51:20 Unable to create machine: error creating machine "10.105.16.15": unable to write secrets to machine: unable to write secret "serviceaccount-key" to machine: unable to create cert dir "/etc/kubernetes/pki" on machine: unable to set permissions to directory "/etc/kubernetes/pki": command failed: Process exited with status 1

This library should not be logging to begin with. If stdout/err is helpful, return it in the error.

sarun87 commented 6 years ago

The error should be returned as part of error. I believe this issue tracks this: https://github.com/platform9/ssh-provider/issues/19