diff --git a/config/config.js b/config/config.js index d95a59c..a340f71 100644 --- a/config/config.js +++ b/config/config.js @@ -37,6 +37,7 @@ var config = { root: path.resolve(certPath,'root.pem') }, gms: { + version: '1.5.3.0', port: 8590, hostname: friendlyHostname !== undefined ? friendlyHostname : globalHostname, routePath: path.join(__dirname, '/../routes/'), diff --git a/routes/routes.js b/routes/routes.js index 02e76f0..0033b9c 100644 --- a/routes/routes.js +++ b/routes/routes.js @@ -184,6 +184,12 @@ router.route('/changeOwner') }); }); +router.route("/version") + .get(function(request, response) + { + response.status(200).send(config.gms.version); + }); + function isEmpty(obj){ for(var prop in obj){ if(obj.hasOwnProperty(prop)) diff --git a/server.js b/server.js index d72d76e..651930b 100644 --- a/server.js +++ b/server.js @@ -74,5 +74,5 @@ app.use('/masterlib',popmasterlib); var server = https.createServer(httpsOptions, app); server.listen(config.gms.port, function() { - logger.info('Governed Metrics Service started',{module:'server'}); + logger.info('Governed Metrics Service version ' + config.gms.version + ' started',{module:'server'}); });