kopia lustrzana https://github.com/c9/core
Merge pull request +12005 from c9/wsmonitor-fixes
WSMonitor path fixespull/248/head
commit
e5e68460b4
|
@ -1,12 +1,13 @@
|
|||
var childProcess = require("child_process");
|
||||
|
||||
var GSSH = __dirname + "/../../scripts/gssh";
|
||||
|
||||
function findServers(pattern, options, callback) {
|
||||
if (!callback && typeof options == "function") {
|
||||
return findServers(pattern, {}, options);
|
||||
}
|
||||
|
||||
childProcess.exec("gssh --print-names " + pattern, function (err, stdout) {
|
||||
childProcess.exec(GSSH + " --print-names " + pattern, function (err, stdout) {
|
||||
if (err) return callback(err);
|
||||
|
||||
var serverNames = stdout.split("\n")
|
||||
|
@ -28,7 +29,7 @@ function runCommand(pattern, command, options, callback) {
|
|||
parallel = " -P"
|
||||
}
|
||||
|
||||
var gsshCommand = "gssh " + parallel + " " + pattern + " '" + command + "'";
|
||||
var gsshCommand = GSSH + " " + parallel + " " + pattern + " '" + command + "'";
|
||||
childProcess.exec(gsshCommand, function (err, stdout) {
|
||||
return callback(err, stdout);
|
||||
});
|
||||
|
|
Ładowanie…
Reference in New Issue