diff --git a/conf/config.example b/conf/config.example index 1e64c5c..f7588b9 100755 --- a/conf/config.example +++ b/conf/config.example @@ -1,6 +1,7 @@ { "interval": 1, "infoApi": true, + "infoApiPort": 9998, "jobs": { "yourSearchJob": { "notification": { diff --git a/lib/api/api.js b/lib/api/api.js index f222568..e35fe58 100644 --- a/lib/api/api.js +++ b/lib/api/api.js @@ -1,7 +1,7 @@ const bodyParser = require('body-parser'); const config = require('../../conf/config'); const { getLastJobExecution, getLastProviderExecution, getTotalNumberOfListings } = require('../services/store'); -const PORT = 9998; +const PORT = config.infoApiPort || 9998; const service = require('restana')(); const enabled = config.infoApi == null ? false : config.infoApi;