Commit Graph

23 Commits

Author SHA1 Message Date
Nathan LeClaire af149d13f7 Fix defaulting to native SSH
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-06-16 10:51:25 -07:00
Evan Hazlett 0b5a389481
fix issue with native ssh; fix tty allocation for redhat
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-06-01 10:08:07 -04:00
Evan Hazlett 04c9e917dd
vbox: fix provisioning hang with tty ssh
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-05-27 08:38:36 -04:00
Nathan LeClaire 93b4799279 Disable password authentication in SSH command
This will turn off the password authentication prompt which some SSH
commands experience if there is a lag between when we attempt the first
SSH command and the key has been loaded on the server.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-05-22 14:02:58 -07:00
Evan Hazlett 5229643a22
ssh: add -t to force tty allocation
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-05-21 14:44:55 -04:00
Evan Hazlett 26432b771f ssh: allocate pty for sudo over ssh for those that have requiretty
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-05-21 13:43:51 -04:00
Nathan LeClaire 2f78b7f92a Move code to use SSH "backends"
Default to shelling out to SSH when available.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-05-19 15:02:57 -07:00
Nathan LeClaire e4785ad879 Move over to real retries method
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-05-15 10:39:39 -07:00
Darren Shepherd 732ca874b8 Fix panic when TCP timeout happens on SSH connect
Signed-off-by: Darren Shepherd <darren@rancher.com>
2015-05-07 13:44:33 -07:00
Evan Hazlett a3e08a010d Merge pull request #1108 from ibuildthecloud/vbox-sleep
Fix issue where GetIP in VirtualBox failes due to no SSH
2015-05-07 13:33:26 -07:00
Nathan LeClaire aa6325dadb Add retries for SSH dial timeout
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-05-06 12:59:46 -07:00
Darren Shepherd 8afe967a80 Fix issue where GetIP failes due to no SSH
The main goal of this patch was to make the VirtualBox driver wait for
SSH before trying to get the IP of the VM.  The generic WaitForSSH
method required a Host struct as an arg.  This patch moves most of the
logic to the driver package so that drivers can call WaitForSSH.  The
existing functions in host are just wrappers to the real
implementation in drivers now.

Signed-off-by: Darren Shepherd <darren@rancher.com>
2015-05-05 09:32:45 -07:00
Nathan LeClaire 142ffadc2c Refactor logging to focus on simple STDOUT/STDERR
This also lays the foundation for the possibility of log drivers in the
future, if it is decided that is a direction to pursue.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-04-30 12:04:52 -07:00
Simon Thulbourn 709b0a84e3 Add SSH client
Signed-off-by: Simon Thulbourn <simon+github@thulbourn.com>
2015-04-21 15:37:09 +01:00
Dave Henderson 7a6c1a7d14 Reducing the number of connection attempts, and setting an explicit timeout of 10 seconds
Signed-off-by: Dave Henderson <Dave.Henderson@ca.ibm.com>
2015-04-15 11:23:08 -04:00
Evan Hazlett 7f55d3ba01
fix ssh key gen bug windows
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-04-10 10:35:25 -04:00
Evan Hazlett dfa155938a Merge pull request #885 from sthulb/ssh-keys
Add SSH key generation
2015-04-10 09:39:24 -04:00
Nathan LeClaire 29999e9b10 Add a few improvements to stability
This improves on a few issues which are not frequent but do sometimes
come up:

1. Check that the daemon is up before attempting to do anything
   docker-ey in provisioning Ubuntu
2. Set a max retries for SSH so that if a request fails it attempts
   again before giving up

Also have annotated a few of the SSH options slightly better.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-04-06 13:00:09 -07:00
Simon Thulbourn 0e23b7c38b Add SSH key generation
Signed-off-by: Simon Thulbourn <simon+github@thulbourn.com>
2015-03-26 19:10:55 +00:00
Evan Hazlett 007d83319d
start on refactor for driver interface
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-03-09 10:12:19 -04:00
Evan Hazlett cf14bac2fc started tests for ssh; added cover tool
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-02-02 15:46:26 -05:00
Simon Thulbourn ab9a19a85b Adds check for SSH keygen command
Adds a check to find ssh-keygen in the user's $PATH, in the event it
can't find it, return an error with a friendly message

Signed-off-by: Simon Thulbourn <simon+github@thulbourn.com>
2015-01-10 12:17:40 +00:00
Ben Firshman 73d19108bf Initial commit
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2014-12-04 15:05:11 +01:00