Merge pull request #528 from charithag/release-2.0.x

Fixed issue in populating server.ip property.
4.x.x
Rasika Perera 8 years ago committed by GitHub
commit 0313707cb4

@ -5,7 +5,7 @@
"httpsWebURL" : "%https.ip%", "httpsWebURL" : "%https.ip%",
"wssURL" : "https://localhost:9445", "wssURL" : "https://localhost:9445",
"wsURL" : "%http.ip%", "wsURL" : "%http.ip%",
"portalURL": "https://${server.ip}:9445", "portalURL": "https://%server.ip%:9445",
"dashboardServerURL" : "%https.ip%", "dashboardServerURL" : "%https.ip%",
"androidEnrollmentDir": "/android-web-agent/enrollment", "androidEnrollmentDir": "/android-web-agent/enrollment",
"windowsEnrollmentDir": "/windows-web-agent/enrollment", "windowsEnrollmentDir": "/windows-web-agent/enrollment",

@ -33,6 +33,9 @@ var conf = function () {
} else if ((typeof value === "string") && value.indexOf("%date-year%") > -1) { } else if ((typeof value === "string") && value.indexOf("%date-year%") > -1) {
var year = new Date().getFullYear(); var year = new Date().getFullYear();
return value.replace("%date-year%", year); return value.replace("%date-year%", year);
} else if ((typeof value === "string") && value.indexOf("%server.ip%") > -1) {
var getProperty = require("process").getProperty;
return value.replace("%server.ip%", getProperty("carbon.local.ip"));
} }
return value; return value;
} }

Loading…
Cancel
Save