Increased NPM install timer from 10 to 120 seconds.

ylianst committed Nov 5, 2019 at 03:20 UTC a97a62b001c6c20de3fcf6fb2b987f7bc6b87a79
3 files changed +2 -2
agents/MeshService.exe
Binary files a/agents/MeshService.exe and /dev/null differ
meshcentral.js
+1 -1
@@ -1953,7 +1953,7 @@ function InstallModule(modulename, func, tag1, tag2) {
1953 if ((__dirname.endsWith('/node_modules/meshcentral')) || (__dirname.endsWith('\\node_modules\\meshcentral')) || (__dirname.endsWith('/node_modules/meshcentral/')) || (__dirname.endsWith('\\node_modules\\meshcentral\\'))) { parentpath = require('path').join(__dirname, '../..'); }
1954
1955 // Looks like we need to keep a global reference to the child process object for this to work correctly.
1956 - InstallModuleChildProcess = child_process.exec('npm install --no-optional --save ' + modulename, { maxBuffer: 512000, timeout: 10000, cwd: parentpath }, function (error, stdout, stderr) {
1956 + InstallModuleChildProcess = child_process.exec('npm install --no-optional --save ' + modulename, { maxBuffer: 512000, timeout: 120000, cwd: parentpath }, function (error, stdout, stderr) {
1957 InstallModuleChildProcess = null;
1958 if ((error != null) && (error != '')) {
1959 console.log('ERROR: Unable to install required module "' + modulename + '". MeshCentral may not have access to npm, or npm may not have suffisent rights to load the new module. Try "npm install ' + modulename + '" to manualy install this module.\r\n');
package.json
+1 -1
@@ -1,6 +1,6 @@
1 {
2 "name": "meshcentral",
3 - "version": "0.4.3-u",
3 + "version": "0.4.3-v",
4 "keywords": [
5 "Remote Management",
6 "Intel AMT",