I am developing an application using node.js(v8.1.4), express and angularjs. Node.js is installed in windows server 8 and I want to connect other windows servers using their respective credentials.
After connection is established, I want to execute commands on remote servers. But I do not know how to connect remote windows server or what package is available for windows connectivity.
For executing commands locally , I am using below code that is working fine,
var exec = require('child_process').exec;
var execcommand = 'dir';
var myproccess = exec(execcommand);
myproccess.stdout.on('data', function(data) {
console.log(data)
}
But I am not getting an idea how to connect remote windows with credentials and execute command.
Please help. I have been struggling with this for many days.
Thanks