Prevent SSH connection restarts
Set a high idle timeout on the sshkit connection pool. This will reduce the incidence of re-connection storms when a deployment has been idle for a while (e.g. when waiting for a docker build). The default timeout was 30 seconds, so we'll enable keepalives at a 30s interval to match. This is to help prevent connections from being killed during long idle periods.
This commit is contained in:
@@ -51,7 +51,7 @@ class MainTest < IntegrationTest
|
||||
assert_equal "app-#{version}", config[:service_with_version]
|
||||
assert_equal [], config[:env_args]
|
||||
assert_equal [], config[:volume_args]
|
||||
assert_equal({ user: "root", auth_methods: [ "publickey" ] }, config[:ssh_options])
|
||||
assert_equal({ user: "root", auth_methods: [ "publickey" ], keepalive: true, keepalive_interval: 30 }, config[:ssh_options])
|
||||
assert_equal({ "multiarch" => false, "args" => { "COMMIT_SHA" => version } }, config[:builder])
|
||||
assert_equal [ "--log-opt", "max-size=\"10m\"" ], config[:logging]
|
||||
assert_equal({ "path" => "/up", "port" => 3000, "max_attempts" => 7, "cmd" => "wget -qO- http://localhost > /dev/null" }, config[:healthcheck])
|
||||
|
||||
Reference in New Issue
Block a user