We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4a96752 commit 588619bCopy full SHA for 588619b
lib/ssh.js
@@ -6,7 +6,7 @@ module.exports = function(opt) {
6
var agent = new http.Agent();
7
8
agent.createConnection = function(options, fn) {
9
- conn.on('ready', function() {
+ conn.once('ready', function() {
10
conn.exec('docker system dial-stdio', function(err, stream) {
11
if (err) {
12
conn.end();
@@ -16,14 +16,14 @@ module.exports = function(opt) {
16
17
fn(null, stream);
18
19
- stream.on('close', () => {
+ stream.once('close', () => {
20
21
agent.destroy();
22
});
23
24
}).connect(opt);
25
26
- conn.on('end', () => agent.destroy());
+ conn.once('end', () => agent.destroy());
27
};
28
29
return agent;
0 commit comments