mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-02-13 03:21:50 +00:00
parent
c01eea2b9d
commit
527add155f
1 changed files with 1 additions and 1 deletions
|
@ -1100,7 +1100,7 @@ function createMeshCore(agent) {
|
||||||
this.prependListener('end', function () { this.httprequest._term.end(function () { console.log('Terminal was closed'); }); });
|
this.prependListener('end', function () { this.httprequest._term.end(function () { console.log('Terminal was closed'); }); });
|
||||||
} else {
|
} else {
|
||||||
if (fs.existsSync("/usr/bin/python") && fs.existsSync("/bin/bash")) {
|
if (fs.existsSync("/usr/bin/python") && fs.existsSync("/bin/bash")) {
|
||||||
this.httprequest.process = childProcess.execFile("/usr/bin/python", [ "python", "-c", "import pty; pty.spawn([\"/bin/bash\"])" ], { type: childProcess.SpawnTypes.TERM });
|
this.httprequest.process = childProcess.execFile("/usr/bin/python", [ "python", "-c", "import pty; pty.spawn([\"/bin/bash\"])" ]);
|
||||||
if (process.platform == 'linux') { this.httprequest.process.stdin.write("export TERM='xterm'\nalias ls='ls --color=auto'\nclear\n"); }
|
if (process.platform == 'linux') { this.httprequest.process.stdin.write("export TERM='xterm'\nalias ls='ls --color=auto'\nclear\n"); }
|
||||||
}
|
}
|
||||||
else if (fs.existsSync("/bin/bash")) {
|
else if (fs.existsSync("/bin/bash")) {
|
||||||
|
|
Loading…
Reference in a new issue