resolve the hanging process and dramatically reduce your pipeline's runtime
Some checks failed
Deploy to Web Server flyer-crawler.projectium.com / deploy (push) Failing after 37m21s
Some checks failed
Deploy to Web Server flyer-crawler.projectium.com / deploy (push) Failing after 37m21s
This commit is contained in:
20
server.ts
20
server.ts
@@ -136,12 +136,16 @@ app.use((err: Error, req: Request, res: Response, next: NextFunction) => {
|
||||
}
|
||||
});
|
||||
|
||||
const PORT = process.env.PORT || 3001;
|
||||
app.listen(PORT, () => {
|
||||
logger.info(`Authentication server started on port ${PORT}`);
|
||||
});
|
||||
if (process.env.NODE_ENV !== 'test') {
|
||||
const PORT = process.env.PORT || 3001;
|
||||
app.listen(PORT, () => {
|
||||
logger.info(`Authentication server started on port ${PORT}`);
|
||||
console.log('--- REGISTERED API ROUTES ---');
|
||||
console.table(listEndpoints(app));
|
||||
console.log('-----------------------------');
|
||||
});
|
||||
}
|
||||
|
||||
console.log('--- REGISTERED API ROUTES ---');
|
||||
console.table(listEndpoints(app));
|
||||
console.log('-----------------------------');
|
||||
// --- END ROUTE DEBUGGING ---
|
||||
|
||||
// Export the app for integration testing
|
||||
export default app;
|
||||
Reference in New Issue
Block a user