Added the basic search, no sorting, no extra stuff.

Added the basic search, no sorting, no extra stuff, raw from elasticsearch.
This commit is contained in:
Fillerino 2017-08-17 18:11:53 +02:00
parent e9ff812273
commit dd74ca7c0a
5 changed files with 73 additions and 16 deletions
server

View file

@ -4,6 +4,11 @@ import logger from 'koa-logger';
import helmet from 'koa-helmet';
import routing from './routes/';
import { port } from './config';
import winston from 'winston';
// Setup logging
winston.remove(winston.transports.Console);
winston.add(winston.transports.Console, {colorize: true});
// Create Koa Application
const app = new Koa();
@ -16,6 +21,6 @@ app
routing(app);
// Start the application
app.listen(port, () => console.log(`✅ The server is running at http://localhost:${port}/`));
app.listen(port, () => winston.log('info', `Lighthouse API server is running at http://localhost:${port}/`));
export default app;