Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 12a8e59

Browse files
Fix health check endpoint
1 parent 4f455b3 commit 12a8e59

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

src/app.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ const routes = require('./routes');
2222
const logger = require('./common/logger');
2323
const errors = require('./common/errors');
2424
const constants = require('./common/constants');
25+
const {getAppHealth} = require('./controllers/AppHealthController');
2526

2627
const app = express();
2728
app.use(cors());
@@ -117,6 +118,8 @@ _.forEach(routes, (verbs, path) => {
117118
});
118119
});
119120

121+
app.get(`/api/${config.API_VERSION}/health`, getAppHealth);
122+
120123
// static content
121124
app.use(express.static(Path.join(__dirname, 'public')));
122125
// mount the angular app

src/routes.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -208,10 +208,4 @@ module.exports = {
208208
method: 'getAppConfig',
209209
},
210210
},
211-
'/health': {
212-
get: {
213-
controller: 'AppHealthController',
214-
method: 'getAppHealth',
215-
},
216-
},
217211
};

0 commit comments

Comments
 (0)