Skip to content
This repository has been archived by the owner on Sep 26, 2021. It is now read-only.

Commit

Permalink
Merge pull request #4451 from krufab/bugfix/ISSUE-4450-use-ssh-server…
Browse files Browse the repository at this point in the history
…aliveinterval

ISSUE-4450 Added ServerAliveInterval among the default ssh options
  • Loading branch information
dgageot authored May 12, 2018
2 parents 0331899 + 8380765 commit 7890e8d
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions libmachine/ssh/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,15 @@ const (
var (
baseSSHArgs = []string{
"-F", "/dev/null",
"-o", "PasswordAuthentication=no",
"-o", "StrictHostKeyChecking=no",
"-o", "UserKnownHostsFile=/dev/null",
"-o", "LogLevel=quiet", // suppress "Warning: Permanently added '[localhost]:2022' (ECDSA) to the list of known hosts."
"-o", "ConnectionAttempts=3", // retry 3 times if SSH connection fails
"-o", "ConnectTimeout=10", // timeout after 10 seconds
"-o", "ControlMaster=no", // disable ssh multiplexing
"-o", "ControlPath=none",
"-o", "LogLevel=quiet", // suppress "Warning: Permanently added '[localhost]:2022' (ECDSA) to the list of known hosts."
"-o", "PasswordAuthentication=no",
"-o", "ServerAliveInterval=60", // prevents connection to be dropped if command takes too long
"-o", "StrictHostKeyChecking=no",
"-o", "UserKnownHostsFile=/dev/null",
}
defaultClientType = External
)
Expand Down

0 comments on commit 7890e8d

Please sign in to comment.