mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
abstracted server start logging
This commit is contained in:
@@ -69,12 +69,16 @@ ROUTES.forEach((route: string) => {
|
||||
});
|
||||
});
|
||||
|
||||
function serverStarted() {
|
||||
console.log(`[${new Date().toTimeString()}] Listening at ${ENV_CONFIG.ui.baseUrl}`);
|
||||
}
|
||||
|
||||
function createHttpsServer(keys) {
|
||||
https.createServer({
|
||||
key: keys.serviceKey,
|
||||
cert: keys.certificate
|
||||
}, app).listen(port, ENV_CONFIG.ui.host, () => {
|
||||
console.log(`Listening at ${ENV_CONFIG.ui.baseUrl}`);
|
||||
serverStarted();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -111,6 +115,6 @@ if (ENV_CONFIG.ui.ssl) {
|
||||
}
|
||||
} else {
|
||||
app.listen(port, ENV_CONFIG.ui.host, () => {
|
||||
console.log(`[${new Date().toTimeString()}] Listening at ${ENV_CONFIG.ui.baseUrl}`);
|
||||
serverStarted();
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user