File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,13 @@ const STATUS_PREFIX = 'CLOUD_INSTALL_STATUS';
3030const INITIAL_CONNECTION_INTERVAL_MS = 500 ;
3131const MAX_CONNECTION_INTERVAL_MS = 10000 ;
3232
33+ // Timeouts for established SSH connections.
34+ // We define these chiefly so that the installer fails quickly
35+ // in case the server is destroyed during installation, e.g.
36+ // when the user cancels install.
37+ const KEEPALIVE_INTERVAL_MS = 1000 ;
38+ const KEEPALIVE_MAX_FAILURES = 5 ;
39+
3340// Installs uProxy on a server, via SSH.
3441// The process is as close as possible to a manual install
3542// so that we have fewer paths to test.
@@ -49,6 +56,8 @@ class CloudInstaller {
4956 port : port ,
5057 username : username ,
5158 privateKey : key ,
59+ keepaliveInterval : KEEPALIVE_INTERVAL_MS ,
60+ keepaliveCountMax : KEEPALIVE_MAX_FAILURES ,
5261 // Remaining fields only for type-correctness.
5362 tryKeyboard : false ,
5463 debug : undefined
You can’t perform that action at this time.
0 commit comments