Log error messages during app Bootstrap.ts
This commit is contained in:
parent
18fef76807
commit
dcc2fb4dc8
@ -39,9 +39,11 @@ export class Bootstrap implements IBootstrap {
|
||||
port: number | string | undefined = process.env.PORT,
|
||||
hostname?: string,
|
||||
) {
|
||||
const apiLogger = loggerFactory.getLogger('api')
|
||||
try {
|
||||
await this.start(port, hostname)
|
||||
} catch (err) {
|
||||
apiLogger.error('Error starting server: %s', err.stack)
|
||||
this.exit(1)
|
||||
throw err
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user