Fixed GreenLock install.
ylianst committed
Nov 6, 2019 at 02:49 UTC
afa1b858ba275e765eedf8a0ea566680fc79e25e
2 files changed
+7
-2
meshcentral.js
+4
-1
@@ -1949,6 +1949,9 @@ function InstallModule(modulename, func, tag1, tag2) {
1949
var child_process = require('child_process');
1950
var parentpath = __dirname;
1951
1952
+ // Add module exact version number if needed
1953
+ if (modulename == 'greenlock') { modulename = 'greenlock@2.8.8'; }
1954
+
1955
// Get the working directory
1956
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, '../..'); }
1957
@@ -2006,7 +2009,7 @@ function mainStart() {
2009
var modules = ['ws', 'cbor', 'nedb', 'https', 'yauzl', 'xmldom', 'ipcheck', 'express', 'archiver', 'multiparty', 'node-forge', 'express-ws', 'compression', 'body-parser', 'connect-redis', 'cookie-session', 'express-handlebars'];
2010
if (require('os').platform() == 'win32') { modules.push('node-windows'); if (sspi == true) { modules.push('node-sspi'); } } // Add Windows modules
2011
if (ldap == true) { modules.push('ldapauth-fork'); }
2009
- if (config.letsencrypt != null) { modules.push('greenlock@2.8.8'); modules.push('le-store-certbot'); modules.push('le-challenge-fs'); modules.push('le-acme-core'); } // Add Greenlock Modules
2012
+ if (config.letsencrypt != null) { modules.push('greenlock'); modules.push('le-store-certbot'); modules.push('le-challenge-fs'); modules.push('le-acme-core'); } // Add Greenlock Modules
2013
if (config.settings.mqtt != null) { modules.push('aedes'); } // Add MQTT Modules
2014
if (config.settings.mongodb != null) { modules.push('mongodb'); } // Add MongoDB, official driver.
2015
if (config.settings.vault != null) { modules.push('node-vault'); } // Add official HashiCorp's Vault module.
package.json
+3
-1
@@ -1,6 +1,6 @@
1
{
2
"name": "meshcentral",
3
- "version": "0.4.3-v",
3
+ "version": "0.4.3-w",
4
"keywords": [
5
"Remote Management",
6
"Intel AMT",
@@ -37,8 +37,10 @@
37
"express": "^4.17.0",
38
"express-handlebars": "^3.1.0",
39
"express-ws": "^4.0.0",
40
+ "greenlock": "^2.8.8",
41
"html-minifier": "^4.0.0",
42
"ipcheck": "^0.1.0",
43
+ "le-acme-core": "^2.1.4",
44
"meshcentral": "*",
45
"minify-js": "0.0.4",
46
"minimist": "^1.2.0",