This commit is contained in:
William Mantly 2016-04-30 23:33:02 -04:00
parent 2a6cce6296
commit c97100c9a7
2 changed files with 3 additions and 2 deletions

2
lxc.js
View File

@ -3,7 +3,7 @@ var exec = require('child_process').exec;
function sysExec(command, callback){ function sysExec(command, callback){
command = new Buffer(command).toString('base64') command = new Buffer(command).toString('base64')
command = 'ssh virt@104.236.77.157 "' + command + '|base64 --decode|bash"'; command = 'ssh virt@104.236.77.157 "echo ' + command + '|base64 --decode|bash"';
// command = 'unset XDG_SESSION_ID XDG_RUNTIME_DIR; cgm movepid all virt $$; ' + command; // command = 'unset XDG_SESSION_ID XDG_RUNTIME_DIR; cgm movepid all virt $$; ' + command;
return exec(command, (function(callback){ return exec(command, (function(callback){

View File

@ -14,7 +14,8 @@ var usedContainers = [];
var exec = require('child_process').exec; var exec = require('child_process').exec;
function sysExec(command, callback){ function sysExec(command, callback){
command = 'ssh virt@104.236.77.157 ' + command; command = new Buffer(command).toString('base64')
command = 'ssh virt@104.236.77.157 "echo ' + command + '|base64 --decode|bash"';
// command = 'unset XDG_SESSION_ID XDG_RUNTIME_DIR; cgm movepid all virt $$; ' + command; // command = 'unset XDG_SESSION_ID XDG_RUNTIME_DIR; cgm movepid all virt $$; ' + command;
return exec(command, (function(callback){ return exec(command, (function(callback){