db-rest/index.js

12 lines
235 B
JavaScript
Raw Permalink Normal View History

2022-12-19 13:23:13 +01:00
import {api, config} from './api.js'
2017-12-16 09:06:35 +01:00
api.listen(config.port, (err) => {
const {logger} = api.locals
2017-10-23 23:13:53 +02:00
if (err) {
logger.error(err)
process.exit(1)
2017-10-23 23:13:53 +02:00
} else {
2022-11-22 16:07:33 +01:00
logger.info(`listening on ${config.port} (${config.hostname}).`)
2017-10-23 23:13:53 +02:00
}
})